summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 847796ac35af1ed60ce5c3ef9c87fd8d78c99400 (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
# Maintainer: coffebar i8ehkvien@mozmail.com

pkgname=waybar-module-pacman-updates-git
pkgver=0.2.7
pkgrel=1
pkgdesc='Waybar module for Arch to show system updates available'
arch=('x86_64')
url="https://github.com/coffebar/waybar-module-pacman-updates"
license=('GPL')
makedepends=(cargo git)
depends=(waybar pacman-contrib)
source=("git+$url#commit=7198f09")
sha256sums=('SKIP')

pkgver(){
  cd "waybar-module-pacman-updates"
  git describe --tags | sed 's/^v//;s/-/+/g'
}

prepare() {
    cd "waybar-module-pacman-updates"
    cargo fetch --target "$CARCH-unknown-linux-gnu"
}

build() {
    cd "waybar-module-pacman-updates"
    export RUSTUP_TOOLCHAIN=stable
    export CARGO_TARGET_DIR=target
    cargo build --frozen --release
}

package() {
    cd "waybar-module-pacman-updates"
  install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/waybar-module-pacman-updates"
}