summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorCore2021-12-08 21:24:08 +0000
committerCore2021-12-08 21:24:08 +0000
commit84b21124a81d4ab16bced9e8d242c085954c0761 (patch)
tree6bf77531875ccb960187a9749e89a44494f6934d
parentb4cfdc7a0f3b580049340b5d433c78d9417185fb (diff)
downloadaur-84b21124a81d4ab16bced9e8d242c085954c0761.tar.gz
Overhaul to PKGBUILD thanks to @FabioLolix
-rw-r--r--.SRCINFO11
-rw-r--r--PKGBUILD25
-rw-r--r--apple-music-electron.install25
3 files changed, 15 insertions, 46 deletions
diff --git a/.SRCINFO b/.SRCINFO
index f50fc8ce98a2..460e0f293850 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,26 +1,19 @@
pkgbase = apple-music-electron-bin
- pkgdesc = An open-source, GPU-accelerated Electron application that emulates the Apple Music website in a customizable interface. Binary release that builds from most recent release on GitHub (Uses .deb file).
+ pkgdesc = An open-source, GPU-accelerated Electron application that emulates the Apple Music website in a customizable interface.
pkgver = 3.0.0
- pkgrel = 2
+ pkgrel = 3
url = https://github.com/CiderApp/Apple-Music-Electron.git
- install = apple-music-electron.install
- arch = i686
arch = x86_64
license = MIT
- makedepends = desktop-file-utils
- makedepends = xdg-utils
depends = gtk3
depends = nss
optdepends = libnotify: Playback notifications
optdepends = otf-san-francisco: Use of SF Font for certain themes
- provides = apple-music-electron-bin
provides = apple-music-electron
conflicts = apple-music-electron
options = !strip
options = !emptydirs
source = https://github.com/CiderApp/Apple-Music-Electron/releases/download/v3.0.0/apple-music-electron_3.0.0_amd64.deb
- source = apple-music-electron.install
sha256sums = d8a91c0171bde307e7da0eb3a40131c999b49c2fa59a7442fbce19f2b9d519b7
- sha256sums = b82a3d4ec0cac09d76346db489faa1a526f3e8e5c2d4d2c56c91416fc9c45f88
pkgname = apple-music-electron-bin
diff --git a/PKGBUILD b/PKGBUILD
index 325b6ff449bc..ee6dd23690dc 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,28 +1,29 @@
# Maintainer: Core_UK <mail.coreuk@gmail.com>
+# Contributor: Fabio Loli <fabio.loli@disroot.org>
pkgname=apple-music-electron-bin
-_pkgnamelow=apple-music-electron
_pkgname=Apple-Music-Electron
pkgver=3.0.0
-pkgrel=2
-pkgdesc="An open-source, GPU-accelerated Electron application that emulates the Apple Music website in a customizable interface. Binary release that builds from most recent release on GitHub (Uses .deb file)."
-arch=('i686' 'x86_64')
+pkgrel=3
+pkgdesc="An open-source, GPU-accelerated Electron application that emulates the Apple Music website in a customizable interface."
+arch=('x86_64')
url="https://github.com/CiderApp/${_pkgname}.git"
license=("MIT")
options=('!strip' '!emptydirs')
-install=${_pkgnamelow}.install
depends=('gtk3' 'nss')
-makedepends=('desktop-file-utils' 'xdg-utils')
optdepends=('libnotify: Playback notifications'
'otf-san-francisco: Use of SF Font for certain themes')
-provides=(${pkgname} ${_pkgnamelow})
-conflicts=(${_pkgnamelow})
-source=("https://github.com/CiderApp/${_pkgname}/releases/download/v${pkgver}/apple-music-electron_${pkgver}_amd64.deb"
- "apple-music-electron.install")
-sha256sums=('d8a91c0171bde307e7da0eb3a40131c999b49c2fa59a7442fbce19f2b9d519b7'
- 'b82a3d4ec0cac09d76346db489faa1a526f3e8e5c2d4d2c56c91416fc9c45f88')
+provides=(apple-music-electron)
+conflicts=(apple-music-electron)
+source=("https://github.com/CiderApp/${_pkgname}/releases/download/v${pkgver}/apple-music-electron_${pkgver}_amd64.deb")
+sha256sums=('d8a91c0171bde307e7da0eb3a40131c999b49c2fa59a7442fbce19f2b9d519b7')
package(){
# Extract package data
tar xf data.tar.xz -C "${pkgdir}"
+
+ chmod 4755 "${pkgdir}/opt/Apple Music/chrome-sandbox"
+
+ install -d "${pkgdir}/usr/bin"
+ ln -sf '/opt/Apple Music/apple-music-electron' "${pkgdir}/usr/bin/apple-music-electron"
}
diff --git a/apple-music-electron.install b/apple-music-electron.install
deleted file mode 100644
index f1809e9ac83d..000000000000
--- a/apple-music-electron.install
+++ /dev/null
@@ -1,25 +0,0 @@
-post_install() {
- gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
-
- # Link to the binary
- ln -sf '/opt/Apple Music/apple-music-electron' '/usr/bin/apple-music-electron'
-
- # SUID chrome-sandbox for Electron 5+
- chmod 4755 '/opt/Apple Music/chrome-sandbox' || true
-
- update-mime-database /usr/share/mime || true
- update-desktop-database /usr/share/applications || true
- update-desktop-database -q
-}
-
-post_upgrade() {
- post_install
-}
-
-post_remove() {
- gtk-update-icon-cache -q -t -f usr/share/icons/hicolor
-
- # Delete the link to the binary
- rm -f '/usr/bin/apple-music-electron'
- update-desktop-database -q
-}