diff options
author | Pipat Saengow | 2016-07-09 00:01:14 +0700 |
---|---|---|
committer | Pipat Saengow | 2016-07-09 00:01:14 +0700 |
commit | a91b1ead663d5a43b09e5528970e7579471c52fd (patch) | |
tree | 1e72c10c86d9c59b11d14d5e415a92d1cd01dc3d | |
download | aur-a91b1ead663d5a43b09e5528970e7579471c52fd.tar.gz |
Initial commit.
-rw-r--r-- | .SRCINFO | 29 | ||||
-rw-r--r-- | INJECTION_0.9.2_src.zip.md5 | 1 | ||||
-rw-r--r-- | PKGBUILD | 52 | ||||
-rw-r--r-- | icon.png | bin | 0 -> 564 bytes | |||
-rw-r--r-- | injection.desktop | 12 | ||||
-rwxr-xr-x | injection.sh | 6 |
6 files changed, 100 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..2b0d9b7211a6 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,29 @@ +pkgbase = injection + pkgdesc = A Python-based ASCII programming-puzzle game. + pkgver = 0.9.2 + pkgrel = 1 + url = https://schilcote.itch.io/injection + arch = i686 + arch = x86_64 + license = MIT + makedepends = unzip + makedepends = curl + makedepends = python-pip + depends = python-pygame + depends = python-pyperclip + depends = python-rsa + depends = python-numpy + depends = cython + depends = tk + depends = python-dill + source = injection.sh + source = injection.desktop + source = icon.png + source = INJECTION_0.9.2_src.zip.md5 + md5sums = 5f21ca7a8891291e250f5296ba855324 + md5sums = cf419413f1dda3dcae7c665c9bb4bf46 + md5sums = 2e6543984ecc80ddf57ed822b344e0e1 + md5sums = d06f2f1c19813ef44a6a62f53c1331b9 + +pkgname = injection + diff --git a/INJECTION_0.9.2_src.zip.md5 b/INJECTION_0.9.2_src.zip.md5 new file mode 100644 index 000000000000..4d7a11861b6e --- /dev/null +++ b/INJECTION_0.9.2_src.zip.md5 @@ -0,0 +1 @@ +5aed878cd844b8e28dd416cd02ce60c9 INJECTION_0.9.2_src.zip diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..15ea1f17dd96 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,52 @@ +# Maintainer: pigt <pay2630 at gmail dot com> +pkgname=injection +pkgver=0.9.2 +pkgrel=1 +pkgdesc="A Python-based ASCII programming-puzzle game." +arch=('i686' 'x86_64') +url="https://schilcote.itch.io/injection" +license=('MIT') +depends=('python-pygame' 'python-pyperclip' 'python-rsa' 'python-numpy' 'cython' 'tk' 'python-dill') +makedepends=('unzip' 'curl' 'python-pip' ) +source=(injection.sh injection.desktop icon.png INJECTION_${pkgver}_src.zip.md5) +md5sums=('5f21ca7a8891291e250f5296ba855324' + 'cf419413f1dda3dcae7c665c9bb4bf46' + '2e6543984ecc80ddf57ed822b344e0e1' + 'd06f2f1c19813ef44a6a62f53c1331b9') + +_release_url="https://schilcote.itch.io/injection/file/235400?after_download_lightbox=true" + +prepare() { + #Download url always changing to prevent hotlink. So we must deal with it. + #url extraction code was copied from "after school"'s package. + _dl_url=$(curl -s -XPOST "${_release_url}" | grep -Po '"url":.*?[^\\]",' | cut -c8- | rev |cut -c3- | rev | sed 's/\\\//\//g') + curl "$_dl_url" -o "INJECTION_${pkgver}_src.zip" + md5sum -c INJECTION_${pkgver}_src.zip.md5 + unzip INJECTION_${pkgver}_src.zip -d "$pkgname-$pkgver" +} + +_python_depends=('pymsgbox' 'pygcurse') +build() { + cd "$pkgname-$pkgver" + + #module that doesn't exist in repo. + mkdir 'custom_packages' + pip install -t 'custom_packages' ${_python_depends[*]} + export PYTHONPATH='./custom_packages' + + #Build fx + python setup.py build_ext + cp build/lib*/* . + rm -r build +} + +package() { + mkdir -p "$pkgdir/usr/lib" + cp -r "$pkgname-$pkgver" "$pkgdir/usr/lib/injection" #Program and assets. + install -D -m644 "$pkgname-$pkgver/LICENSE" "$pkgdir/usr/share/licenses/injection/LICENSE" #License. + install -D -m755 "injection.sh" "$pkgdir/usr/lib/injection/injection.sh" #Launch script. + mkdir "$pkgdir/usr/bin/" + ln -s "/usr/lib/injection/injection.sh" "$pkgdir/usr/bin/injection" + install -D -m644 "injection.desktop" "$pkgdir/usr/share/applications/injection.desktop" + install -D -m644 "icon.png" "$pkgdir/usr/lib/injection/icon.png" +} diff --git a/icon.png b/icon.png Binary files differnew file mode 100644 index 000000000000..03acf85906ac --- /dev/null +++ b/icon.png diff --git a/injection.desktop b/injection.desktop new file mode 100644 index 000000000000..114255c4c725 --- /dev/null +++ b/injection.desktop @@ -0,0 +1,12 @@ +[Desktop Entry] + +Type=Application +Version=1.0 +Name=INJECTION +Comment=A Python-based ASCII programming-puzzle game. +Path=/usr/lib/injection +Exec=injection +Icon=/usr/lib/injection/icon.png +Terminal=false + + diff --git a/injection.sh b/injection.sh new file mode 100755 index 000000000000..f47ac90dbeb9 --- /dev/null +++ b/injection.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +cd '/usr/lib/injection' +export PYTHONPATH="$(pwd)/custom_packages" + +python main.py "$@" |