diff options
author | Jonathan Zacsh | 2021-11-26 00:06:41 -0600 |
---|---|---|
committer | Jonathan Zacsh | 2021-11-26 00:06:41 -0600 |
commit | 9fe3014add8e75650be7a6c98afedb31ef51fb22 (patch) | |
tree | 622866a4b31cec8d9a690f7e49223ab6778aad50 | |
parent | 9b032852f8b8b62e3fe08422f65176f1362149b6 (diff) | |
download | aur-9fe3014add8e75650be7a6c98afedb31ef51fb22.tar.gz |
bugfix: help pacman detect new upstream pidcat
this is a correction to the final bullet in commit message
9b032852f8b8b62 - I was confused there. Some more manual testing
clarified what was going on. Indeed the function _has_ to be hand
defined else versioning doesn't bump up correctly.
Tested this manually with:
```sh
$ makepkg
$ pacman -Qip $path_to_pkg_tar_zst
# see output shows a useful version bump now , eg:
Version : 2.1.0.r14.0cb1c2c-1
```
-rw-r--r-- | PKGBUILD | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -1,7 +1,7 @@ # Maintainer: Jonathan Zacsh <j@zac.sh> pkgname=pidcat-git -pkgver=2.1.0 +pkgver=2.1.0.r14.0cb1c2c pkgrel=1 pkgdesc="Pidcat is a colored logcat script with improved readability that only shows log entries for a specific Android package." arch=('any') @@ -23,3 +23,9 @@ package() { # Install run script install -Dm755 "$srcdir"/pidcat/pidcat.py "$pkgdir"/usr/bin/pidcat } + +pkgver() { + # per https://gitlab.archlinux.org/pacman/pacman/blob/edce7555a6b7410d1a4da6d27d22383989306ccc/proto/PKGBUILD-vcs.proto#L46 + cd "$srcdir/${pkgname%-git}" + git describe --long | sed 's/\([^-]*-\)g/r\1/;s/-/./g' +} |