summaryrefslogtreecommitdiffstats
path: root/dijo-git/PKGBUILD
blob: 75931d7b3dc1689a42d7c55b181213b0ad7baa48 (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
# Maintainer: Yigit Sever <yigit at yigitsever dot com>
# Contributor: quininer <quininer at live dot com>

pkgname='dijo-git'
_pkgname="dijo"
pkgver=0.2.7.191.gbe6e0e3
pkgrel=1
arch=('x86_64' 'i686')
url="https://github.com/NerdyPepper/dijo"
pkgdesc="scriptable, curses-based, digital habit tracker"
license=('MIT')
depends=()
makedepends=('rust' 'cargo' 'git')
checkdepends=()
provides=('dijo')
conflicts=('dijo')
source=("$_pkgname::git+https://github.com/NerdyPepper/dijo.git")
sha256sums=('SKIP')

pkgver() {
	cd $_pkgname
	echo "$(grep '^version =' Cargo.toml|head -n1|cut -d\" -f2|cut -d\- -f1).$(git rev-list --count HEAD).g$(git rev-parse --short HEAD)"
}

build(){
	cd "$_pkgname"
	cargo build --release --locked
}

package() {
	cd $_pkgname
	install -D -m755 "target/release/dijo" "$pkgdir/usr/bin/dijo"
	install -D -m644 "dijo.1" "$pkgdir/usr/share/man/man1/dijo.1"
}