blob: 38893bddc3193d3de00cf5a751779cd7465fa8ce (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
# Maintainer: Gaurav Atreya <allmanpride at gmail dot com>
pkgname=onchange-git
pkgver=0.1.1
pkgrel=1
pkgdesc="Tool to run commands on file change"
arch=('x86_64')
url="https://github.com/Atreyagaurav/${pkgname%-git}"
license=('GPL3')
depends=('gcc-libs')
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
makedepends=('rust' 'cargo' 'git')
source=("git+https://github.com/Atreyagaurav/${pkgname%-git}.git")
md5sums=('SKIP')
pkgver() {
cd "$srcdir/${pkgname%-git}"
printf "%s" "$(git describe --tags --abbrev=0 | sed 's/\([^-]*-\)g/r\1/;s/-/./g')"
}
prepare() {
cd "$srcdir/${pkgname%-git}"
git checkout "tags/$(git describe --tags --abbrev=0)"
}
build() {
cd "$srcdir/${pkgname%-git}"
cargo build --release
}
package() {
cd "$srcdir/${pkgname%-git}"
mkdir -p "$pkgdir/usr/bin"
cp "target/release/${pkgname%-git}" "$pkgdir/usr/bin/${pkgname%-git}"
}
|