summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuis Martinez2021-09-19 00:29:22 -0500
committerLuis Martinez2021-09-19 00:29:22 -0500
commitf2e6a224e9ee2535db4840a4aa1f30d7a63b2d44 (patch)
treeaa53440eda7fcc163716d8face422de5160556f2
parentb7b5162dc46a820dc84f0e2552ae2bd2bad66f51 (diff)
downloadaur-f2e6a224e9ee2535db4840a4aa1f30d7a63b2d44.tar.gz
package cleanup
-rw-r--r--.SRCINFO18
-rw-r--r--.gitignore4
-rw-r--r--CHANGELOG.md56
-rw-r--r--PKGBUILD57
4 files changed, 94 insertions, 41 deletions
diff --git a/.SRCINFO b/.SRCINFO
index bf7845309ad4..d43cc5c5e0a9 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,17 +1,19 @@
pkgbase = python-cohesion
- pkgdesc = A tool for measuring Python class cohesion.
+ pkgdesc = Measures Python class cohesion
pkgver = 1.0.0
- pkgrel = 2
+ pkgrel = 3
url = https://github.com/mschwager/cohesion
+ changelog = CHANGELOG.md
arch = any
- license = GPL
- makedepends = python
+ license = GPL3
+ checkdepends = python-nose2>=0.6.5
+ checkdepends = python-pytest-cov
+ checkdepends = python-coveralls>=1.1
+ checkdepends = python-pyfakefs>=2.7
makedepends = python-setuptools
depends = python
- optdepends = flake8: Flake8 Support
- options = !emptydirs
- source = https://github.com/mschwager/cohesion/archive/1.0.0.tar.gz
+ optdepends = flake8
+ source = python-cohesion-1.0.0.tar.gz::https://github.com/mschwager/cohesion/archive/1.0.0.tar.gz
sha256sums = abb5a88b70de96e7dfb65244cc13cff7e9c5edee5333175d5a7668ac7c742c6c
pkgname = python-cohesion
-
diff --git a/.gitignore b/.gitignore
deleted file mode 100644
index 4df5cbd2d036..000000000000
--- a/.gitignore
+++ /dev/null
@@ -1,4 +0,0 @@
-*
-!.SRCINFO
-!.gitignore
-!PKGBUILD
diff --git a/CHANGELOG.md b/CHANGELOG.md
new file mode 100644
index 000000000000..fa395856652b
--- /dev/null
+++ b/CHANGELOG.md
@@ -0,0 +1,56 @@
+# Change Log
+All notable changes to this project will be documented in this file.
+This project adheres to [Semantic Versioning](http://semver.org/).
+This project adheres to [CHANGELOG](http://keepachangelog.com/).
+
+## [Unreleased]
+
+## [1.0.0] - 2019-07-10
+### Changed
+- Enable cohesion by default
+
+### Fixed
+- Debugging and standard output not producing the same results
+
+## [0.9.1] - 2018-09-20
+### Fixed
+- Package long description content type
+
+## [0.9.0] - 2018-09-20
+### Added
+- Python 3.7 support
+
+### Fixed
+- Bug with setuptools specifying cohesion_below option as a str
+
+## [0.8.0] - 2017-10-01
+### Added
+- Flake8 support
+- Filtering on cohesion values below/above a certain threshold
+- Class line number and column offset in output
+
+### Removed
+- Python 3.2 and 3.3 support
+
+## [0.7.0] - 2017-06-15
+### Added
+- Python 3.6 support
+
+## [0.6.1] - 2016-09-21
+### Changed
+- Improved instance variable detection
+- Improved attribute value name detection
+
+## [0.6.0] - 2016-08-27
+### Added
+- Added functionality for printing staticmethod and classmethod information
+- Added -x flag for debugging output
+
+## [0.5.1] - 2016-08-16
+### Changed
+- Moved to standard Python package __main__ functionality to support Python 2
+ and 3
+
+## [0.5.0] - 2016-08-16
+### Added
+- Initial release of Cohesion
diff --git a/PKGBUILD b/PKGBUILD
index 53a8b1162af4..6c67986ae090 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,39 +1,38 @@
-# Maintainer: Kaizhao Zhang <zhangkaizhao@gmail.com>
+# Maintainer: Luis Martinez <luis dot martinez at disroot dot org>
+# Contributor: Kaizhao Zhang <zhangkaizhao@gmail.com>
-_name=cohesion
-_version=1.0.0
-_sha256sum=abb5a88b70de96e7dfb65244cc13cff7e9c5edee5333175d5a7668ac7c742c6c
-
-pkgname="python-${_name}"
-pkgver="${_version}"
-pkgrel=2
-pkgdesc="A tool for measuring Python class cohesion."
+pkgname=python-cohesion
+pkgver=1.0.0
+pkgrel=3
+pkgdesc='Measures Python class cohesion'
arch=('any')
url="https://github.com/mschwager/cohesion"
-license=('GPL')
+license=('GPL3')
depends=('python')
-makedepends=('python' 'python-setuptools')
-optdepends=(
- 'flake8: Flake8 Support'
-)
-options=(!emptydirs)
-source=(
- #"https://files.pythonhosted.org/packages/py2.py3/${_name:0:1}/${_name}/${_name}-${_version}-py2.py3-none-any.whl"
- "${url}/archive/${_version}.tar.gz"
-)
-sha256sums=(
- "${_sha256sum}"
-)
+optdepends=('flake8')
+makedepends=('python-setuptools')
+checkdepends=(
+ 'python-nose2>=0.6.5'
+ 'python-pytest-cov'
+ 'python-coveralls>=1.1' ## AUR
+ 'python-pyfakefs>=2.7')
+changelog=CHANGELOG.md
+source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz")
+sha256sums=('abb5a88b70de96e7dfb65244cc13cff7e9c5edee5333175d5a7668ac7c742c6c')
build() {
- cd "${srcdir}/${_name}-${_version}"
- python setup.py build
+ cd "cohesion-$pkgver"
+ python setup.py build
+}
+
+check() {
+ cd "cohesion-$pkgver"
+ nose2
}
package() {
- cd "${srcdir}/${_name}-${_version}"
- install -Dm644 README.md "${pkgdir}/usr/share/doc/${pkgname}/README.md"
- install -Dm644 CHANGELOG.md "${pkgdir}/usr/share/doc/${pkgname}/CHANGELOG.md"
- install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
- python setup.py install --root="${pkgdir}/" --optimize=1 --skip-build
+ cd "cohesion-$pkgver"
+ python setup.py install --root="$pkgdir/" --optimize=1 --skip-build
+ install -Dm644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname/"
+ install -Dm644 README.md -t "$pkgdir/usr/share/doc/$pkgname/"
}