summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorKokaKiwi2022-09-01 12:55:11 +0200
committerKokaKiwi2022-09-01 12:55:11 +0200
commita45f208dfc58a216d0e03647b479b4ee34b03e11 (patch)
tree5055bd12173beefe6c2fed29fc5cb7e79cbbc583
parentf0ebfc150129d552bc64ddc28ca2cf66e42bbd26 (diff)
downloadaur-a45f208dfc58a216d0e03647b479b4ee34b03e11.tar.gz
Generate shell completions and manpage
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD14
2 files changed, 13 insertions, 3 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 4462f21b147b..8b49f517a736 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = trashy
pkgdesc = a cli system trash manager, alternative to rm and trash-cli
pkgver = 1.0.3
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/oberblastmeister/trashy
arch = x86_64
arch = aarch64
diff --git a/PKGBUILD b/PKGBUILD
index c83b68d569b1..9942e682d883 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=trashy
pkgver=1.0.3
-pkgrel=1
+pkgrel=2
pkgdesc='a cli system trash manager, alternative to rm and trash-cli'
url="https://github.com/oberblastmeister/trashy"
license=('MIT' 'Apache')
@@ -19,7 +19,7 @@ export RUSTUP_TOOLCHAIN=${RUSTUP_TOOLCHAIN:-stable}
prepare() {
cd "$pkgname-$pkgver"
- cargo fetch --locked
+ cargo fetch --locked --target "$CARCH-unknown-linux-gnu"
}
build() {
@@ -27,6 +27,11 @@ build() {
CARGO_TARGET_DIR='target' \
cargo build --frozen --release --all-features
+
+ target/release/trash completions zsh > _trash.zsh
+ target/release/trash completions bash > trash.bash
+ target/release/trash completions fish > trash.fish
+ target/release/trash manpage > trash.1
}
package() {
@@ -34,5 +39,10 @@ package() {
install -Dm0755 -t "$pkgdir/usr/bin" target/release/trash
+ install -Dm0644 _trash.zsh "$pkgdir/usr/share/zsh/site-functions/_trash"
+ install -Dm0644 trash.bash "$pkgdir/usr/share/bash-completion/completions/trash"
+ install -Dm0644 trash.fish "$pkgdir/usr/share/fish/vendor_completions.d/trash.fish"
+ install -Dm0644 trash.1 "$pkgdir/usr/share/man/man1/trash.1"
+
install -Dm0644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE-{APACHE,MIT}
}