diff --git a/packaging/arch/PKGBUILD b/packaging/arch/PKGBUILD new file mode 100644 index 0000000..6a7ebb3 --- /dev/null +++ b/packaging/arch/PKGBUILD @@ -0,0 +1,27 @@ +# Maintainer: Jack O'Connor + +pkgname=peru-git +pkgdesc='A tool for fetching code' +url='https://github.com/buildinspace/peru' +license=('MIT') +pkgver=0 +pkgver() { + cd "$srcdir/peru" + echo $(git rev-list --count master).$(git rev-parse --short master) +} +pkgrel=1 +arch=('any') +# Asyncio and pathlib are standard in Python 3.4, so they're not in the +# dependencies list. +depends=(python python-yaml python-docopt git) +optdepends=( + 'mercurial: fetching from hg repos' + 'subversion: fetching from svn repos' +) +source=('git://github.com/buildinspace/peru') +md5sums=('SKIP') + +package() { + cd "$srcdir/peru" + python3 setup.py install --root="$pkgdir" +} diff --git a/packaging/arch/makelocal.sh b/packaging/arch/makelocal.sh new file mode 100755 index 0000000..fa728cb --- /dev/null +++ b/packaging/arch/makelocal.sh @@ -0,0 +1,17 @@ +#! /bin/bash + +# By default, makepkg clones the source repo from github before building. To +# package your local copy of the sources (including any changes you've made), +# use this script. +# +# See `man makepkg` for relevant options, like -d to ignore missing +# dependencies. (The only dependency needed for packaging is python.) + +set -e + +cd $(dirname "$BASH_SOURCE") +rm -rf src +mkdir src +ln -s ../../../.. src/peru + +makepkg -e "$@"