summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Meow2020-09-04 19:27:56 +0300
committerJohn Meow2020-09-04 19:27:56 +0300
commita9bfeb7112a1498cd0dcd1fdcd2a0540ccf42353 (patch)
tree4ab15a2e1ae0dbec75752e453a92dea3e9865dc7
parent15d0faeb250fea8eb23d011a2a519654138bfc48 (diff)
downloadaur-a9bfeb7112a1498cd0dcd1fdcd2a0540ccf42353.tar.gz
Improve PKGBUILD
-rw-r--r--.SRCINFO7
-rw-r--r--PKGBUILD21
2 files changed, 18 insertions, 10 deletions
diff --git a/.SRCINFO b/.SRCINFO
index c26dfde54c5..df730ddd8df 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = silver-git
pkgdesc = A cross-shell customizable powerline-like prompt with icons
- pkgver = 1.1.0
- pkgrel = 1
+ pkgver = v1.1.0.r49.g105d298
+ pkgrel = 2
arch = i686
arch = x86_64
arch = armv6h
@@ -9,6 +9,9 @@ pkgbase = silver-git
license = MIT
makedepends = rust
makedepends = cargo
+ makedepends = git
+ source = git+https://github.com/reujab/silver.git#branch=master
+ md5sums = SKIP
pkgname = silver-git
diff --git a/PKGBUILD b/PKGBUILD
index 6567b2e6ca5..006f9e1a196 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,17 +1,22 @@
# Maintainer: reujab <reujab@gmail.com>
-pkgname=silver-git
-pkgver=1.1.0
-pkgrel=1
-makedepends=('rust' 'cargo')
+_pkgname=silver
+pkgname=$_pkgname-git
+pkgver=v1.1.0.r49.g105d298
+pkgrel=2
+makedepends=('rust' 'cargo' 'git')
arch=('i686' 'x86_64' 'armv6h' 'armv7h')
pkgdesc="A cross-shell customizable powerline-like prompt with icons"
license=('MIT')
+source=(git+https://github.com/reujab/silver.git#branch=master)
+md5sums=('SKIP')
-build() {
- return 0
+pkgver() {
+ cd "$srcdir/$_pkgname"
+ git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}
package() {
- cd $srcdir
- cargo install --root="$pkgdir" --git=https://github.com/reujab/silver
+ cd "$srcdir/$_pkgname"
+ cargo install --locked --all-features --no-track --root "$pkgdir/usr/" --path .
+ install -Dm644 license "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}