summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorPedroHLC2019-12-25 15:15:04 +0100
committerPedroHLC2019-12-25 15:15:04 +0100
commit3e31e5a4cd1b40240c3c3f075cb7b0413ba31aaa (patch)
tree8f892024e27f23ca73b10489c1829bdbfbd18180
parentbd406fcd734b1a2ec76a9138b3ab52935dd48058 (diff)
downloadaur-3e31e5a4cd1b40240c3c3f075cb7b0413ba31aaa.tar.gz
Fix cause pkgver runs after prepare!
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD11
2 files changed, 7 insertions, 6 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 9fbc49b405a..ff4ddbfaf84 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -11,7 +11,7 @@ pkgbase = repoctl-devel-git
makedepends = git
depends = pacman
options = !strip
- source = repoctl-devel-git::git+https://github.com/cassava/repoctl.git#branch=devel
+ source = repoctl::git+https://github.com/cassava/repoctl.git#branch=devel
md5sums = SKIP
pkgname = repoctl-devel-git
diff --git a/PKGBUILD b/PKGBUILD
index 90ad1f565e6..1dee9ddee2f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,8 @@
# Contributor: Alad Wenter <alad@mailbox.org>
# Contributor: Ben Morgan <neembi@gmail.com>
# Contributor: Stefan Husmann <stefan-husmann@t-online.de>
-pkgname=repoctl-devel-git
+_pkgname=repoctl
+pkgname="${_pkgname}-devel-git"
pkgver=0.19
pkgrel=0
pkgdesc="A supplement to repo-add and repo-remove which simplifies managing local repositories (devel branch from git)"
@@ -12,11 +13,11 @@ license=('MIT')
depends=('pacman')
makedepends=('go' 'git')
options=('!strip')
-source=("$pkgname::git+https://github.com/cassava/repoctl.git#branch=devel")
+source=("${_pkgname}::git+https://github.com/cassava/repoctl.git#branch=devel")
md5sums=('SKIP')
pkgver() {
- cd "$pkgname"
+ cd "${_pkgname}"
git describe --tags --long | sed 's/^v//; s/-/.r/; s/-/./g'
}
@@ -25,7 +26,7 @@ prepare() {
mkdir -p "$dest"
mv "$srcdir/$pkgname" "$dest/repoctl"
cd "$srcdir"
- ln -s "$dest/repoctl" "$pkgname-$pkgver"
+ ln -s "$dest/repoctl" "${_pkgname}"
}
build() {
@@ -35,7 +36,7 @@ build() {
}
package() {
- cd "${srcdir}/${pkgname}"
+ cd "${srcdir}/${_pkgname}"
# Install repoctl program
install -d "$pkgdir/usr/bin"