diff options
author | Alexandre Jesus | 2017-08-13 14:24:33 +0100 |
---|---|---|
committer | Alexandre Jesus | 2017-08-13 14:24:33 +0100 |
commit | f13201e2c5f0ec2440872df391150bb70fc4009a (patch) | |
tree | 7d4c6bdad3d067e766c257488691817611c9f95f | |
download | aur-f13201e2c5f0ec2440872df391150bb70fc4009a.tar.gz |
Setup soccer-cli
-rw-r--r-- | .SRCINFO | 18 | ||||
-rw-r--r-- | PKGBUILD | 38 | ||||
-rw-r--r-- | soccer-cli-git.install | 6 |
3 files changed, 62 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..17d0a2f04e0f --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,18 @@ +pkgbase = soccer-cli-git + pkgdesc = Soccer for Hackers - a CLI for all the football scores. + pkgver = 20170813_r262.429f2d3 + pkgrel = 1 + url = https://github.com/architv/soccer-cli + install = soccer-cli-git.install + arch = any + license = MIT + makedepends = git + depends = python2 + depends = python2-click + depends = python2-requests + provides = soccer-cli + source = git+https://github.com/architv/soccer-cli.git + md5sums = SKIP + +pkgname = soccer-cli-git + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..d1fb7062ad60 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,38 @@ +# Maintainer: Alexandre Jesus <adbjesus@gmail.com> + +_pkgname=soccer-cli +pkgname=${_pkgname}-git +pkgver=20170813_r262.429f2d3 +pkgrel=1 +pkgdesc="Soccer for Hackers - a CLI for all the football scores." +arch=('any') +url="https://github.com/architv/soccer-cli" +license=('MIT') +depends=('python2' 'python2-click' 'python2-requests') +makedepends=('git') +provides=("${_pkgname}") +source=('git+https://github.com/architv/soccer-cli.git') +md5sums=('SKIP') +install="${pkgname}.install" + +pkgver() { + cd "${srcdir}/${_pkgname}" + + # Get the version number. + printf "%s_r%s.%s" "$(date +%Y%m%d)" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" +} + +build() { + cd "$srcdir/${_pkgname}" + + sed -i -e 's/requests==2/requests>=2/' setup.py +} + +package() { + cd "$srcdir/${_pkgname}" + + install -D -m644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + + python2 setup.py install --root="$pkgdir/" --optimize=1 +} + diff --git a/soccer-cli-git.install b/soccer-cli-git.install new file mode 100644 index 000000000000..ee8b1648d45f --- /dev/null +++ b/soccer-cli-git.install @@ -0,0 +1,6 @@ +post_install() { + echo "" + echo "The env variable SOCCER_CLI_API_TOKEN is required, with an API key from football-data.org" + echo "" +} + |