build-scripts/arch/license-tool/PKGBUILD

30 lines
692 B
Bash

# Maintainer: Alexander Rosenberg <zanderpkg at pm dot me>
pkgname='license-tool'
pkgver=5
pkgrel=1
pkgdesc='A simple tool for creating LICENSE files'
url='https://git.zander.im/Zander671/license-tool'
arch=('x86_64')
license=('GPL3')
depends=('rust')
source=('git+https://git.zander.im/Zander671/license-tool.git')
sha256sums=('SKIP')
pkgver(){
cd "$pkgname"
git rev-list --count HEAD
}
build() {
cd "$pkgname"
export GLOBAL_DATA_PATH='/usr/share/license-tool/'
cargo build --release
}
package() {
install -Dt "$pkgdir/usr/bin/" "$pkgname/target/release/license-tool"
mkdir -p "$pkgdir/usr/share/"
cp -r "$pkgname/licenses" "$pkgdir/usr/share/license-tool"
}