mirror of
https://git.sanhost.net/sanasol/hytale-f2p
synced 2026-02-26 09:21:48 -03:00
aur: add proper VCS (-git) PKGBUILD
created clean VCS-based PKGBUILD following arch packaging conventions. this explicitly marked as a rolling (-git) build and derives its version dynamically from git tags and commit history via pkgver(). previous hybrid approach has been changed. key changes: - use -git suffix to clearly indicate rolling source builds - set pkgver=0 and compute the actual version via pkgver() - build only a directory layout using electron-builder (--dir) - avoid generating AppImage, deb, rpm, or pacman installers - align build and package steps with Arch packaging guidelines note: this PKGBUILD is intended for development and AUR use only and is not suitable for binary redistribution or release artifacts.
This commit is contained in:
33
PKGBUILD
33
PKGBUILD
@@ -1,33 +0,0 @@
|
|||||||
# Maintainer: Terromur <terromuroz@proton.me>
|
|
||||||
pkgname=Hytale-F2P-git
|
|
||||||
_pkgname=Hytale-F2P
|
|
||||||
pkgver=2.0.12.r150.gb62ffc1
|
|
||||||
pkgrel=1
|
|
||||||
pkgdesc="Hytale-F2P - unofficial Hytale Launcher for free to play with multiplayer support"
|
|
||||||
arch=('x86_64')
|
|
||||||
url="https://github.com/amiayweb/Hytale-F2P"
|
|
||||||
license=('custom')
|
|
||||||
makedepends=('npm' 'git' 'rpm-tools' 'libxcrypt-compat')
|
|
||||||
source=("git+$url.git" "Hytale-F2P.desktop")
|
|
||||||
sha256sums=('SKIP' '46488fada4775d9976d7b7b62f8d1f1f8d9a9a9d8f8aa9af4f2e2153019f6a30')
|
|
||||||
|
|
||||||
pkgver() {
|
|
||||||
cd "$_pkgname"
|
|
||||||
version=$(git describe --abbrev=0 --tags --match "v[0-9]*")
|
|
||||||
commits=$(git rev-list --count HEAD)
|
|
||||||
hash=$(git rev-parse --short HEAD)
|
|
||||||
printf "%s.r%s.g%s" "${version#v}" "$commits" "$hash"
|
|
||||||
}
|
|
||||||
|
|
||||||
build() {
|
|
||||||
cd "$_pkgname"
|
|
||||||
npm ci
|
|
||||||
npm run build:linux
|
|
||||||
}
|
|
||||||
|
|
||||||
package() {
|
|
||||||
mkdir -p "$pkgdir/opt/$_pkgname"
|
|
||||||
cp -r "$_pkgname/dist/linux-unpacked/"* "$pkgdir/opt/$_pkgname"
|
|
||||||
install -Dm644 "$_pkgname.desktop" "$pkgdir/usr/share/applications/$_pkgname.desktop"
|
|
||||||
install -Dm644 "$_pkgname/GUI/icon.png" "$pkgdir/usr/share/icons/hicolor/256x256/apps/$_pkgname.png"
|
|
||||||
}
|
|
||||||
33
PKGBUILD-git
Normal file
33
PKGBUILD-git
Normal file
@@ -0,0 +1,33 @@
|
|||||||
|
# Maintainer: Terromur <terromuroz@proton.me>
|
||||||
|
pkgname=Hytale-F2P-git
|
||||||
|
_pkgname=Hytale-F2P
|
||||||
|
pkgver=0
|
||||||
|
pkgrel=1
|
||||||
|
pkgdesc="Hytale-F2P - Unofficial Hytale Launcher for free to play with multiplayer support (rolling git build)"
|
||||||
|
arch=('x86_64')
|
||||||
|
url="https://github.com/amiayweb/Hytale-F2P"
|
||||||
|
license=('custom')
|
||||||
|
depends=('gtk3' 'nss' 'libxcrypt-compat')
|
||||||
|
makedepends=('git' 'npm')
|
||||||
|
source=("git+$url.git" "$_pkgname.desktop")
|
||||||
|
sha256sums=('SKIP' '46488fada4775d9976d7b7b62f8d1f1f8d9a9a9d8f8aa9af4f2e2153019f6a30')
|
||||||
|
|
||||||
|
pkgver() {
|
||||||
|
cd "$srcdir/$_pkgname"
|
||||||
|
git describe --tags --long | sed 's/^v//;s/-/.r/;s/-/./'
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
cd "$srcdir/$_pkgname"
|
||||||
|
npm ci
|
||||||
|
npm run build:arch
|
||||||
|
}
|
||||||
|
|
||||||
|
package() {
|
||||||
|
cd "$srcdir/$_pkgname"
|
||||||
|
install -d "$pkgdir/opt/$_pkgname"
|
||||||
|
cp -r "$_pkgname/dist/linux-unpacked/"* "$pkgdir/opt/$_pkgname"
|
||||||
|
|
||||||
|
install -Dm644 "$srcdir/$_pkgname.desktop" "$pkgdir/usr/share/applications/$_pkgname.desktop"
|
||||||
|
install -Dm644 GUI/icon.png "$pkgdir/usr/share/icons/hicolor/256x256/apps/$_pkgname.png"
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user