diff options
author | André Kugland | 2024-03-09 23:30:18 -0300 |
---|---|---|
committer | André Kugland | 2024-03-09 23:30:18 -0300 |
commit | 4f98c185fd98c2b8a4ee487d69ac1cf938ab9d4b (patch) | |
tree | 09218b000415f9d6f8f880b9a8cf323dd1997579 | |
download | aur-4f98c185fd98c2b8a4ee487d69ac1cf938ab9d4b.tar.gz |
First commit @ 0.1.11.r3.g2fd2edc
-rw-r--r-- | .SRCINFO | 13 | ||||
-rw-r--r-- | PKGBUILD | 44 |
2 files changed, 57 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..9e021c90d2b8 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,13 @@ +pkgbase = neocities-deploy-git + pkgdesc = Command-line tool for deploying your Neocities site + pkgver = 0.1.11.r3.g2fd2edc + pkgrel = 1 + url = https://github.com/kugland/neocities-deploy + arch = any + license = GPL3 + makedepends = cargo + options = !lto + source = neocities-deploy::git+https://github.com/kugland/neocities-deploy#branch=master + sha256sums = SKIP + +pkgname = neocities-deploy-git diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..f458f879170a --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,44 @@ +# Maintainer: André Kugland <kugland@gmail.com> + +_pkgname=neocities-deploy +pkgname=$_pkgname-git +pkgdesc='Command-line tool for deploying your Neocities site' +url="https://github.com/kugland/$_pkgname" +pkgver=0.1.11.r3.g2fd2edc +pkgrel=1 +arch=('any') +source=("$_pkgname::git+${url}#branch=master") +sha256sums=('SKIP') +makedepends=(cargo) +license=('GPL3') +options=(!lto) + +prepare() { + cd "$srcdir/$_pkgname" + export RUSTUP_TOOLCHAIN=stable + cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')" +} + +build() { + cd "$srcdir/$_pkgname" + export RUSTUP_TOOLCHAIN=stable + export CARGO_TARGET_DIR=target + cargo build --release --all-features --frozen +} + +check() { + cd "$srcdir/$_pkgname" + export RUSTUP_TOOLCHAIN=stable + cargo test --all-features --frozen +} + +package() { + cd "$srcdir/$_pkgname" + install -Dm0755 -t "$pkgdir/usr/bin/" "target/release/$_pkgname" + install -Dm0644 -t "$pkgdir/usr/doc/$_pkgname/" README.md +} + +pkgver() { + cd "$srcdir/$_pkgname" + git describe --long --abbrev=7 | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} |