mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-23 19:25:25 +03:00
testing/icdiff: new aport
This commit is contained in:
parent
d337fb8675
commit
e8f73f8d82
3 changed files with 76 additions and 0 deletions
40
testing/icdiff/APKBUILD
Normal file
40
testing/icdiff/APKBUILD
Normal file
|
@ -0,0 +1,40 @@
|
||||||
|
# Contributor: Kevin Daudt <kdaudt@alpinelinux.org>
|
||||||
|
# Maintainer: Kevin Daudt <kdaudt@alpinelinux.org>
|
||||||
|
pkgname=icdiff
|
||||||
|
pkgver=1.9.4
|
||||||
|
pkgrel=0
|
||||||
|
pkgdesc="Improved colored diff"
|
||||||
|
url="http://www.jefftk.com/icdiff"
|
||||||
|
arch="noarch"
|
||||||
|
license="Python-2.0"
|
||||||
|
depends="python3 py3-setuptools"
|
||||||
|
makedepends="python3-dev"
|
||||||
|
checkdepends="py3-flake8"
|
||||||
|
source="https://github.com/jeffkaufman/icdiff/archive/release-$pkgver.tar.gz
|
||||||
|
fix-flake8-binary.patch
|
||||||
|
fix-python-interpreter.patch
|
||||||
|
"
|
||||||
|
builddir="$srcdir/icdiff-release-$pkgver"
|
||||||
|
|
||||||
|
prepare() {
|
||||||
|
default_prepare
|
||||||
|
|
||||||
|
# patch removes executable bit
|
||||||
|
chmod +x test.sh icdiff
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
python3 setup.py build
|
||||||
|
}
|
||||||
|
|
||||||
|
check() {
|
||||||
|
./test.sh python3
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
python3 setup.py install --prefix=/usr --root="$pkgdir"
|
||||||
|
}
|
||||||
|
|
||||||
|
sha512sums="aca036d5e7661796ba8cc5efd0fc9ad5175e134045d88855d5a8295ab90822040b28adc830a6bc5e19089e244f63d87f4d1adc5c0e6d6ef36edab34057dda9a0 release-1.9.4.tar.gz
|
||||||
|
fc6fa3c98b245a9ce1830428c1d59b37f75faaab00dbf44a6d78f84318cfb4bf3fdc826fc86b9ca8a9efbd2a760223525270ea79e4d761e64d4a18597693eb64 fix-flake8-binary.patch
|
||||||
|
949b3935c44ea2982949bf2389023f091a7e96d61bd05561cddf1f4baccb13da7bf138ac1707e5727190703f539ddca8ddacb79546d6d35a14a4e7e6c63685e4 fix-python-interpreter.patch"
|
24
testing/icdiff/fix-flake8-binary.patch
Normal file
24
testing/icdiff/fix-flake8-binary.patch
Normal file
|
@ -0,0 +1,24 @@
|
||||||
|
diff --git a/test.sh b/test.sh
|
||||||
|
old mode 100755
|
||||||
|
new mode 100644
|
||||||
|
index b44425d817..be8eb15fa9
|
||||||
|
--- a/test.sh
|
||||||
|
+++ b/test.sh
|
||||||
|
@@ -129,7 +129,7 @@ if [ "$VERSION" != $(head -n 1 ChangeLog) ]; then
|
||||||
|
fail
|
||||||
|
fi
|
||||||
|
|
||||||
|
-if ! command -v 'flake8' >/dev/null 2>&1; then
|
||||||
|
+if ! command -v 'flake8-3' >/dev/null 2>&1; then
|
||||||
|
echo 'Could not find flake8. Ensure flake8 is installed and on your $PATH.'
|
||||||
|
if [ -z "$VIRTUAL_ENV" ]; then
|
||||||
|
echo 'It appears you have have forgotten to activate your virtualenv.'
|
||||||
|
@@ -139,7 +139,7 @@ if ! command -v 'flake8' >/dev/null 2>&1; then
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo 'Running flake8 linter...'
|
||||||
|
-if ! flake8 icdiff; then
|
||||||
|
+if ! flake8-3 icdiff; then
|
||||||
|
fail
|
||||||
|
fi
|
||||||
|
|
12
testing/icdiff/fix-python-interpreter.patch
Normal file
12
testing/icdiff/fix-python-interpreter.patch
Normal file
|
@ -0,0 +1,12 @@
|
||||||
|
diff --git a/icdiff b/icdiff
|
||||||
|
old mode 100755
|
||||||
|
new mode 100644
|
||||||
|
index 3e4e8721e8..b24847eac6
|
||||||
|
--- a/icdiff
|
||||||
|
+++ b/icdiff
|
||||||
|
@@ -1,4 +1,4 @@
|
||||||
|
-#!/usr/bin/env python
|
||||||
|
+#!/usr/bin/env python3
|
||||||
|
|
||||||
|
""" icdiff.py
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue