update rust package template
This commit is contained in:
parent
43bcff2ab3
commit
a176f5879d
1 changed files with 8 additions and 1 deletions
|
@ -1,9 +1,16 @@
|
||||||
pkgname=
|
pkgname=
|
||||||
pkgver=
|
pkgver=
|
||||||
|
|
||||||
|
_clear_vendor_checksums() {
|
||||||
|
sed -i 's/\("files":{\)[^}]*/\1/' vendor/$1/.cargo-checksum.json
|
||||||
|
}
|
||||||
|
|
||||||
fetch() {
|
fetch() {
|
||||||
curl "" -o $pkgname-$pkgver.tar.xz
|
curl "" -o $pkgname-$pkgver.tar.xz
|
||||||
tar -xf $pkgname-$pkgver.tar.xz
|
tar -xf $pkgname-$pkgver.tar.xz
|
||||||
|
cd $pkgname-$pkgver
|
||||||
|
mkdir -p .cargo
|
||||||
|
cargo vendor > .cargo/config
|
||||||
}
|
}
|
||||||
|
|
||||||
build() {
|
build() {
|
||||||
|
@ -13,7 +20,7 @@ build() {
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
cd $pkgname-$pkgver
|
cd $pkgname-$pkgver
|
||||||
install -Dm 755 target/release/${pkgname} -t "${pkgdir}/usr/bin"
|
install -Dm755 target/release/$pkgname $pkgdir/usr/bin/$pkgname
|
||||||
}
|
}
|
||||||
|
|
||||||
license() {
|
license() {
|
||||||
|
|
Loading…
Reference in a new issue