mirror of
https://github.com/cucumber-sp/yandex-music-linux.git
synced 2024-12-24 14:34:39 +03:00
new pkgbuild template
This commit is contained in:
parent
a558dcf73b
commit
ceb7c569e1
@ -1,26 +1,40 @@
|
|||||||
# Maintainer: Andrey Onischenko loraner123@gmail.com
|
# Maintainer: Andrey Onischenko loraner123@gmail.com
|
||||||
|
|
||||||
pkgname=yandexmusic-bin
|
pkgname=yandexmusic-bin
|
||||||
pkgver=%version%
|
pkgver=VERSION
|
||||||
pkgrel=1
|
pkgrel=RELEASE_NUMBER
|
||||||
pkgdesc="Yandex Music Client"
|
pkgdesc="Yandex Music Client"
|
||||||
arch=('any')
|
arch=("any")
|
||||||
url="https://github.com/cucumber-sp/yandex-music-linux"
|
url="https://github.com/cucumber-sp/yandex-music-linux"
|
||||||
license=('custom')
|
license=("custom")
|
||||||
depends=('electron' 'libpulse')
|
depends=("electron" "libpulse")
|
||||||
|
makedepends=("p7zip" "nodejs" "jq")
|
||||||
|
|
||||||
source=('./yandexmusic.asar' './yandexmusic.desktop' './LICENSE.md')
|
source=("https://music-desktop-application.s3.yandex.net/stable/Yandex_Music_x64_$pkgver.exe" "https://github.com/cucumber-sp/yandex-music-linux/archive/v$pkgver-$pkgrel.tar.gz")
|
||||||
sha256sums=('%asar_hash%' '%desktop_hash%' 'SKIP')
|
sha256sums=("EXE_HASH" "SOURCE_HASH")
|
||||||
|
|
||||||
|
prepare() {
|
||||||
|
npm install @electron/asar;
|
||||||
|
}
|
||||||
|
|
||||||
|
build() {
|
||||||
|
arch_dir="yandex-music-linux-$pkgver-$pkgrel"
|
||||||
|
mv "$srcdir/Yandex_Music_x64_$pkgver.exe" "$srcdir/$arch_dir"
|
||||||
|
cd "$srcdir/$arch_dir"
|
||||||
|
sh "./repack.sh" "Yandex_Music_x64_$pkgver.exe"
|
||||||
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
|
arch_dir="yandex-music-linux-$pkgver-$pkgrel"
|
||||||
mkdir -p "$pkgdir/usr/lib/yandexmusic"
|
mkdir -p "$pkgdir/usr/lib/yandexmusic"
|
||||||
mkdir -p "$pkgdir/usr/share/applications"
|
mkdir -p "$pkgdir/usr/share/applications"
|
||||||
mkdir -p "$pkgdir/usr/bin"
|
mkdir -p "$pkgdir/usr/bin"
|
||||||
|
|
||||||
install -Dm644 "$srcdir/yandexmusic.asar" "$pkgdir/usr/lib/yandexmusic/yandexmusic.asar"
|
install -Dm644 "$srcdir/$arch_dir/out/yandexmusic.asar" "$pkgdir/usr/lib/yandexmusic/yandexmusic.asar"
|
||||||
install -Dm644 "$srcdir/yandexmusic.desktop" "$pkgdir/usr/share/applications/yandexmusic.desktop"
|
install -Dm644 "$srcdir/$arch_dir/out/yandexmusic.desktop" "$pkgdir/usr/share/applications/yandexmusic.desktop"
|
||||||
install -Dm644 "$srcdir/LICENSE.md" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
install -Dm644 "$srcdir/$arch_dir/LICENSE.md" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
||||||
|
|
||||||
|
rm -rf "$srcdir/$arch_dir"
|
||||||
|
|
||||||
# Create a script to launch the app with Electron
|
# Create a script to launch the app with Electron
|
||||||
echo "#!/bin/sh" > "$pkgdir/usr/bin/yandexmusic"
|
echo "#!/bin/sh" > "$pkgdir/usr/bin/yandexmusic"
|
||||||
|
Loading…
Reference in New Issue
Block a user