diff options
author | James An | 2017-01-26 01:12:57 -0500 |
---|---|---|
committer | James An | 2017-01-26 01:12:57 -0500 |
commit | 93f686d4eccba939a78cac6973db5522c44551f3 (patch) | |
tree | 904fafa530b48066e2e4feeec7c5309faf41d5f6 | |
download | aur-93f686d4eccba939a78cac6973db5522c44551f3.tar.gz |
Initial commit with working PKGBUILD.
-rw-r--r-- | .SRCINFO | 21 | ||||
-rw-r--r-- | .gitignore | 19 | ||||
-rw-r--r-- | PKGBUILD | 54 | ||||
-rw-r--r-- | test.patch | 27 |
4 files changed, 121 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..bddcb2d79199 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,21 @@ +pkgbase = dupd-git + pkgdesc = CLI utility to find duplicate files + pkgver = 1.3.r83.ged1888f + pkgrel = 1 + url = http://www.virkki.com/dupd + arch = i686 + arch = x86_64 + arch = any + license = GPL3 + makedepends = git + provides = dupd=1.3.r83.ged1888f + conflicts = dupd + source = dupd::git+https://github.com/jvirkki/dupd.git + source = libbloom::git+https://github.com/jvirkki/libbloom.git + source = test.patch + md5sums = SKIP + md5sums = SKIP + md5sums = 5228e790f359376d51a9348cb72092eb + +pkgname = dupd-git + diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..785639149fd4 --- /dev/null +++ b/.gitignore @@ -0,0 +1,19 @@ +### https://raw.github.com/github/gitignore/a41bfbea916d6d2e010d0d232895f9c65bd0d502/ArchLinuxPackages.gitignore + +*.tar +*.tar.* +*.jar +*.exe +*.msi +*.zip +*.tgz +*.log +*.log.* +*.sig + +pkg/ +src/ + +# Ignore package source folders +*/* + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..8dc4121f901c --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,54 @@ +# Maintainer: James An <james@jamesan.ca> + +pkgname=dupd-git +_pkgname=${pkgname%-git} +pkgver=1.3.r83.ged1888f +pkgrel=1 +pkgdesc="CLI utility to find duplicate files" +arch=('i686' 'x86_64' 'any') +url="http://www.virkki.com/$_pkgname" +license=('GPL3') +makedepends=('git') +provides=("$_pkgname=$pkgver") +conflicts=("$_pkgname") +source=("$_pkgname"::"git+https://github.com/jvirkki/$_pkgname.git" + "libbloom"::"git+https://github.com/jvirkki/libbloom.git" + test.patch) +md5sums=('SKIP' + 'SKIP' + '5228e790f359376d51a9348cb72092eb') + +pkgver() { + cd "$_pkgname" + ( + set -o pipefail + git describe --long --tag | sed -r 's/([^-]*-g)/r\1/;s/-/./g' || + printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" + ) +} + +prepare() { + cd "$_pkgname" + + patch -p1 -i ../test.patch +} + +build() { + cd libbloom && make && cd .. + cd "$_pkgname" + + make +} + +check() { + cd "$_pkgname" + mv tests/{,~}test.72 + + make test +} + +package() { + cd "$_pkgname" + + install -Dm755 "$_pkgname" "$pkgdir/usr/bin/$_pkgname" +} diff --git a/test.patch b/test.patch new file mode 100644 index 000000000000..9fa947a9954d --- /dev/null +++ b/test.patch @@ -0,0 +1,27 @@ +diff --git a/tests/output.72~ b/tests/output.72~ +new file mode 100644 +index 0000000..995afc7 +--- /dev/null ++++ b/tests/output.72~ +@@ -0,0 +1,8 @@ ++ ++ ++ ++ 1 ++ 3 ++ 5 ++33 total bytes used by duplicates: ++Total used: 33 bytes (0 KiB, 0 MiB, 0 GiB) +diff --git a/tests/test.72 b/tests/test.72 +index ba1cc70..51e536e 100755 +--- a/tests/test.72 ++++ b/tests/test.72 +@@ -12,7 +12,7 @@ checkrv $? + DESC="report" + $DUPD_CMD report --cut `pwd`/files8/ | grep -v "Duplicate report from database" > nreport + checkrv $? +-check_nreport output.72 ++check_nreport output.72~ + + (cd ./files8 && ./clean_files) + |