summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authoracxz2022-09-05 18:06:23 -0400
committeracxz2022-09-05 18:06:23 -0400
commit4e7a2cbc3d98c800eae0472e1f568985c17c8a49 (patch)
tree51020a87806791e7cc7ed9f4addbcb50818b692d
parent473228eb19774cf423a2b31a8d295977e030d759 (diff)
downloadaur-pokeshell.tar.gz
upgpkg: pokeshell 1.0.0-8
change upstream source
-rw-r--r--.SRCINFO20
-rw-r--r--PKGBUILD52
-rw-r--r--pokeshell.install25
3 files changed, 29 insertions, 68 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 6a6786121918..c45e0c6b0af6 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,15 +1,15 @@
pkgbase = pokeshell
- pkgdesc = Displays pokemons in your shell
+ pkgdesc = A shell program to show pokemon sprites in the terminal.
pkgver = 1.0.0
- pkgrel = 7
- url = https://pokeapi.co/
- install = pokeshell.install
+ pkgrel = 8
+ url = https://github.com/acxz/pokeshell
arch = any
- license = MIT
- makedepends = curl
- makedepends = imagemagick
- makedepends = img2xterm
- options = !emptydirs
+ license = GPLv3
+ depends = curl
+ depends = jq
+ depends = imagemagick
+ depends = chafa
+ source = pokeshell-1.0.0.tar.gz::https://github.com/acxz/pokeshell/archive/v1.0.0.tar.gz
+ sha256sums = d968781b1ede645c6528eefaf49dcf945eff0e19b8b02686414e3ec2b169e129
pkgname = pokeshell
-
diff --git a/PKGBUILD b/PKGBUILD
index da4117ca808c..47cfcb675620 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,43 +1,29 @@
# Maintainer: Ricardo (XenGi) Band <email@ricardo.band>
-_maxwidth=80
-_maxheight=22
-_firstpokemon=1
-_lastpokemon=151
-
pkgname=pokeshell
pkgver=1.0.0
-pkgrel=7
-pkgdesc="Displays pokemons in your shell"
-url="https://pokeapi.co/"
-arch=(any)
-license=('MIT')
-makedepends=('curl' 'imagemagick' 'img2xterm')
-options=(!emptydirs)
-install='pokeshell.install'
+pkgrel=8
+pkgdesc="A shell program to show pokemon sprites in the terminal."
+arch=('any')
+url='https://github.com/acxz/pokeshell'
+license=('GPLv3')
+depends=('curl' 'jq' 'imagemagick' 'chafa')
+source=("${pkgname}-${pkgver}.tar.gz::https://github.com/acxz/pokeshell/archive/v${pkgver}.tar.gz")
+sha256sums=('d968781b1ede645c6528eefaf49dcf945eff0e19b8b02686414e3ec2b169e129')
build() {
- cd "$srcdir/"
- for _i in `seq $_firstpokemon 1 $_lastpokemon` ; do
- printf "Generating Pokemon #$_i"
- # download pokemon image
- curl -sL https://raw.githubusercontent.com/PokeAPI/sprites/master/sprites/pokemon/$_i.png -o $_i.png
- printf "."
- # trim image
- convert $_i.png -trim -resize ${_maxwidth}x$(($_maxheight * 2))\> $_i.png
- printf "."
- # convert to escape sequences
- img2xterm $_i.png > $_i.pokemon
- printf ". done\n"
- # cleanup
- rm -f $_i.png
- done
+ msg "Nothing to build"
}
package() {
- cd "$srcdir/"
- for _i in `seq $_firstpokemon 1 $_lastpokemon` ; do
- install -D -m644 $_i.pokemon "${pkgdir}/usr/share/${pkgname}/$_i.pokemon"
- done
-}
+ cd "${srcdir}/${pkgname}-${pkgver}"
+
+ mkdir -p ${pkgdir}/usr/bin
+ cp -v bin/pokeshell ${pkgdir}/usr/bin
+ mkdir -p ${pkgdir}/usr/share/bash-completion/completions
+ cp -v share/bash-completion/completions/pokeshell ${pkgdir}/usr/share/bash-completion/completions/pokeshell
+
+ # mkdir -p ${pkgdir}/usr/share/zsh/site-functions
+ # cp -v share/zsh/site-functions/_pokeshell ${pkgdir}/usr/share/zsh/site-functions/_pokeshell
+}
diff --git a/pokeshell.install b/pokeshell.install
deleted file mode 100644
index 73d1f534dce1..000000000000
--- a/pokeshell.install
+++ /dev/null
@@ -1,25 +0,0 @@
-post_install() {
- echo "put something like this at the end of your ~/.bashrc to get a random pokemon on every bash launch:"
- echo ""
- echo "cat /usr/share/pokeshell/\$((\$RANDOM % 151 + 1)).pokemon"
- echo ""
- echo "For fish shell you customize your greeting function by changing ~/.config/fish/functions/fish_prompt.fish:"
- echo ""
- echo "function fish_greeting"
- echo " set r (random)"
- echo " cat /usr/share/pokeshell/(math \"\$r % 151 + 1\").pokemon"
- echo "end"
-}
-
-post_upgrade() {
- echo "put something like this at the end of your ~/.bashrc to get a random pokemon on every bash launch:"
- echo ""
- echo "cat /usr/share/pokeshell/\$((\$RANDOM % 151 + 1)).pokemon"
- echo ""
- echo "For fish shell you customize your greeting function by changing ~/.config/fish/functions/fish_prompt.fish:"
- echo ""
- echo "function fish_greeting"
- echo " set r (random)"
- echo " cat /usr/share/pokeshell/(math \"\$r % 151 + 1\").pokemon"
- echo "end"
-}