blob: 9455a41356bac8666bf4c317cb3662c878fa87d6 (
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
36
37
38
|
# Maintainer: sty <pbk at tuta dot io>
pkgname=cargo-run-script-git
pkgver=r11.96df282
pkgrel=1
pkgdesc="A Cargo subcommand which allows you to define scripts for common project related tasks within your 'Cargo.toml'."
arch=(x86_64)
url=https://github.com/JoshMcguigan/cargo-run-script
license=(Apache-2.0 MIT)
depends=(gcc-libs glibc cargo)
makedepends=(git)
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
source=("$pkgname::git+https://github.com/JoshMcguigan/cargo-run-script")
sha256sums=('SKIP')
pkgver() {
cd "$srcdir/$pkgname"
printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
prepare() {
cd "$srcdir/$pkgname"
export RUSTUP_TOOLCHAIN=stable
cargo fetch --locked --target "$(rustc -vV | sed -n 's/host: //p')"
}
check() {
cd "$srcdir/$pkgname"
export RUSTUP_TOOLCHAIN=stable
cargo test --frozen --all-features
}
package() {
cd "$srcdir/$pkgname"
export RUSTUP_TOOLCHAIN=stable
cargo install --no-track --all-features --root "$pkgdir/usr/" --path .
install -Dm644 LICENSE-MIT.txt "$pkgdir/usr/share/licenses/$pkgname/LICENSE-MIT"
}
|