summaryrefslogtreecommitdiff
path: root/user
diff options
context:
space:
mode:
authorMax Rees <maxcrees@me.com>2018-09-12 17:23:55 -0400
committerMax Rees <maxcrees@me.com>2018-09-17 23:08:30 -0400
commite25cc595324f27bbaa1d5e90e1cfcd05981dd980 (patch)
tree868ddd3c6a54065c2b00fbaec8323faa9432ee2c /user
parent16ba484a7abb982fbccb7f0f45650423c1d4b723 (diff)
downloadpackages-e25cc595324f27bbaa1d5e90e1cfcd05981dd980.tar.gz
packages-e25cc595324f27bbaa1d5e90e1cfcd05981dd980.tar.bz2
packages-e25cc595324f27bbaa1d5e90e1cfcd05981dd980.tar.xz
packages-e25cc595324f27bbaa1d5e90e1cfcd05981dd980.zip
user/checkbashisms: new package
Diffstat (limited to 'user')
-rw-r--r--user/checkbashisms/APKBUILD43
1 files changed, 43 insertions, 0 deletions
diff --git a/user/checkbashisms/APKBUILD b/user/checkbashisms/APKBUILD
new file mode 100644
index 000000000..c85d7cc54
--- /dev/null
+++ b/user/checkbashisms/APKBUILD
@@ -0,0 +1,43 @@
+# Contributor: Natanael Copa <ncopa@alpinelinux.org>
+# Maintainer: Max Rees <maxcrees@me.com>
+pkgname=checkbashisms
+pkgver=2.18.4
+pkgrel=0
+pkgdesc="Check shell scripts for POSIX compliance"
+url="https://tracker.debian.org/pkg/devscripts"
+arch="noarch"
+license="GPL-2.0+"
+makedepends=""
+depends="perl"
+checkdepends="shunit2"
+subpackages="$pkgname-doc $pkgname-bash-completion:bashcomp:noarch"
+source="http://cdn.debian.net/debian/pool/main/d/devscripts/devscripts_$pkgver.tar.xz"
+builddir="$srcdir/devscripts-$pkgver"
+
+prepare() {
+ default_prepare
+ sed -i "s/###VERSION###/$pkgver/" "scripts/$pkgname.pl"
+}
+
+check() {
+ cd "$builddir"
+ ./test/test_checkbashisms
+}
+
+package() {
+ cd "$builddir"
+ install -Dm755 "scripts/$pkgname.pl" "$pkgdir/usr/bin/$pkgname"
+ install -Dm644 "scripts/$pkgname.1" "$pkgdir/usr/share/man/man1/$pkgname.1"
+}
+
+bashcomp() {
+ pkgdesc="Bash completions for $pkgname"
+ depends=""
+ install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
+
+ cd "$builddir"
+ install -Dm644 "scripts/$pkgname.bash_completion" \
+ "$subpkgdir/usr/share/bash-completion/completions/$pkgname"
+}
+
+sha512sums="91a0ab2fa1f8d884d79f62d5cc8170c885c24af51de321a41f2111fe0fbc0fd8394e5fb3825eeee14d8090968be35761080a40cb55339b09522219d974f63897 devscripts_2.18.4.tar.xz"