pkgbuild script and desktop entry

This commit is contained in:
unittensor 2023-09-08 20:56:22 -04:00
parent f95055bf4d
commit ed8d6f4ef2
2 changed files with 40 additions and 0 deletions

32
pkg/PKGBUILD Normal file
View File

@ -0,0 +1,32 @@
# Maintainer: Brandon <brandon@rhpidfyre.io>
pkgname=strafe-client-git
pkgver=0.0.73.05156d1
pkgrel=1
pkgdesc="In development client for jumping on squares (and riding on triangles)"
arch=(x86_64)
url="https://git.itzana.me/StrafesNET/strafe-client"
license=('custom')
makedepends=(git rust)
source=(git+${url}.git)
md5sums=("SKIP")
_strafe_client_app="src/strafe-client"
pkgver(){
cd "../${_strafe_client_app}"
printf "0.0.%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}
build(){
cd "../${_strafe_client_app}"
cargo build --release
}
package(){
cd "../${_strafe_client_app}"
install -Dm 755 "target/release/strafe-client" "${pkgdir}/usr/bin/strafe-client"
install -Dm 644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
cd "pkg/"
install -Dm 644 "${pkgdir}/strafe-512.png" "${pkgdir}/usr/share/pixmaps/strafe.png"
for pngsize in 22 24 32 48 64 128 256 512; do
install -Dm 644 "strafe-$pngsize.png" "${pkgdir}/usr/share/icons/hicolor/${pngsize}x${pngsize}/apps/strafe.png"
done
install -Dm 644 "strafe-client.desktop" "${pkgdir}/usr/share/applications/strafe-client.desktop"
}

View File

@ -0,0 +1,8 @@
[Desktop Entry]
Version=0.2.0
Type=Application
Name=Strafe Client
Comment=Client for jumping on squares (and riding on triangles)
Icon=strafe
Exec=/usr/bin/strafe-client
Categories=Games;