Package Details: pokemonsay-newgenerations-git 2.0.1-1

Git Clone URL: https://aur.archlinux.org/pokemonsay-newgenerations-git.git (read-only, click to copy)
Package Base: pokemonsay-newgenerations-git
Description: Brings pokemon to the terminal using the power of cowsay.
Upstream URL: https://github.com/HRKings/pokemonsay-newgenerations.git
Keywords: cli cowsay fortune pokemon pokemonsay pokeshell
Licenses: MIT
Provides: pokemonsay
Submitter: HRKings
Maintainer: HRKings
Last Packager: HRKings
Votes: 1
Popularity: 0.000000
First Submitted: 2021-05-24 22:34 (UTC)
Last Updated: 2021-10-05 01:01 (UTC)

Latest Comments

exploder-jimmy commented on 2026-04-09 08:29 (UTC) (edited on 2026-04-09 08:33 (UTC) by exploder-jimmy)

Hello. I suggest the following changes:

# Maintainer: HRKings <hrkings@***.com>
_pkgname=pokemonsay-newgenerations
pkgname=${_pkgname}-git
pkgver=2.0.0.r0.gf8a24a0
pkgrel=1
pkgdesc='Like cowsay but for pokemon only'
arch=(any)
url='https://github.com/HRKings/pokemonsay-newgenerations'
license=('MIT')
depends=(cowsay)
makedepends=(git)
provides=(pokemonsay $_pkgname)
conflicts=($_pkgname)
source=("${_pkgname}::git+${url}")
md5sums=('SKIP')

pkgver() {
    cd ${_pkgname}
    printf -- '%s.r%s.g%s' \
        "$(git describe --tags --abbrev=0 | sed 's/^v//')" \
        "$(git rev-list --count "$(git describe --tags --abbrev=0)"...HEAD)" \
        "$(git rev-parse --short=7 HEAD)"
}

prepare() {
    cd ${_pkgname}

    # Run grep first to make sure match is found in files

    echo 'Changing installation path in pokemonsay.sh...'
    grep -q '^INSTALL_PATH=.*$' pokemonsay.sh
    sed 's#^INSTALL_PATH=.*$#INSTALL_PATH=/usr/share/'"${_pkgname}"'#' -i pokemonsay.sh

    echo 'Changing command in pokemonthink.sh...'
    grep -q '^./pokemonsay.sh --think .*$' pokemonthink.sh
    sed 's#^./pokemonsay.sh --think .*$#pokemonsay --think "$@"#' -i pokemonthink.sh
}

package() {
    cd ${_pkgname}
    # Install pokemon cowfiles
    install -Dm644 -t "${pkgdir}/usr/share/${_pkgname}/pokemons" pokemons/*

    # Install the README and LICENSE
    install -Dm644 -t "${pkgdir}/usr/share/doc/${_pkgname}" README.md
    install -Dm644 -t "${pkgdir}/usr/share/doc/${_pkgname}/res" res/example.png
    install -Dm644 -t "${pkgdir}/usr/share/licenses/${_pkgname}" LICENSE

    # Install the scripts
    install -Dm755 pokemonsay.sh "${pkgdir}"/usr/bin/pokemonsay
    install -Dm755 pokemonthink.sh "${pkgdir}"/usr/bin/pokemonthink
}