summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO8
-rw-r--r--PKGBUILD32
2 files changed, 21 insertions, 19 deletions
diff --git a/.SRCINFO b/.SRCINFO
index b6960cca01fd..5add09e5c2ab 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,16 +1,16 @@
# Generated by mksrcinfo v8
-# Sat Jan 2 01:33:40 UTC 2016
+# Mon Feb 8 20:57:53 UTC 2016
pkgbase = bash-common-parse-options
pkgdesc = An easier way to parse CLI options for Bash scripts
- pkgver = 0.0.3
+ pkgver = 0.0.4
pkgrel = 1
url = https://github.com/vinsonchuong/bash-common-parse-options
arch = any
license = MIT
checkdepends = bats-git
makedepends = clidoc
- source = https://github.com/vinsonchuong/bash-common-parse-options/archive/v0.0.3-1.tar.gz
- md5sums = 0fb2d6ee36044113ecddd36fb47af1b5
+ source = https://github.com/vinsonchuong/bash-common-parse-options/archive/v0.0.4-1.tar.gz
+ md5sums = SKIP
pkgname = bash-common-parse-options
diff --git a/PKGBUILD b/PKGBUILD
index 8594d557fc21..18828c7210ec 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,6 +1,6 @@
# Maintainer: Vinson Chuong <vinsonchuong@gmail.com>
pkgname=bash-common-parse-options
-pkgver=0.0.3
+pkgver=0.0.4
pkgrel=1
pkgdesc=An\ easier\ way\ to\ parse\ CLI\ options\ for\ Bash\ scripts
arch=(any)
@@ -8,29 +8,31 @@ url=https://github.com/vinsonchuong/bash-common-parse-options
license=(MIT)
makedepends=(clidoc)
checkdepends=(bats-git)
-source=(https://github.com/vinsonchuong/bash-common-parse-options/archive/v0.0.3-1.tar.gz)
-md5sums=('0fb2d6ee36044113ecddd36fb47af1b5')
+source=(https://github.com/vinsonchuong/bash-common-parse-options/archive/v0.0.4-1.tar.gz)
+md5sums=("SKIP")
build ()
{
cd "${srcdir}/${pkgname}-${pkgver}-${pkgrel}";
- if [[ -d 'doc' ]]; then
- clidoc doc/*.md;
- fi
+ clidoc doc/*.md
}
check ()
{
cd "${srcdir}/${pkgname}-${pkgver}-${pkgrel}";
- if [[ -d 'spec' ]]; then
- bats spec;
- fi
+ PATH="${PWD}/bin:${PATH}" bats spec
}
package ()
{
cd "${srcdir}/${pkgname}-${pkgver}-${pkgrel}";
- [ -d 'bin' ] && install -Dm755 -t "${pkgdir}/usr/bin" bin/*;
- [ -d 'help' ] && install -Dm644 -t "${pkgdir}/usr/share/${pkgname}/help" help/*;
- [ -f 'README.md' ] && install -Dm644 -t "${pkgdir}/usr/share/doc/${pkgname}" 'README.md';
- [ -d 'doc' ] && install -Dm644 -t "${pkgdir}/usr/share/doc/${pkgname}/doc" doc/*.md;
- [ -f 'LICENSE' ] && install -Dm644 -t "${pkgdir}/usr/share/licenses/${pkgname}" 'LICENSE';
- [ -d 'man' ] && install -Dm644 -t "${pkgdir}/usr/share/man/man1" man/*
+ [[ -d 'bin' ]] && install -Dm755 -t "${pkgdir}/usr/bin" bin/*;
+ if [[ -d 'lib' ]]; then
+ for file in $(find 'lib' -type 'f');
+ do
+ install -D -m "$(stat -c '%a' "$file")" "$file" "${pkgdir}/usr/lib/${pkgname}/${file#'lib/'}";
+ done;
+ fi;
+ [[ -d 'help' ]] && install -Dm644 -t "${pkgdir}/usr/share/${pkgname}/help" help/*;
+ [[ -f 'README.md' ]] && install -Dm644 -t "${pkgdir}/usr/share/doc/${pkgname}" 'README.md';
+ [[ -d 'doc' ]] && install -Dm644 -t "${pkgdir}/usr/share/doc/${pkgname}/doc" doc/*.md;
+ [[ -f 'LICENSE' ]] && install -Dm644 -t "${pkgdir}/usr/share/licenses/${pkgname}" 'LICENSE';
+ [[ -d 'man' ]] && install -Dm644 -t "${pkgdir}/usr/share/man/man1" man/*
}