summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorzxp198210052023-12-13 12:50:20 +0800
committerzxp198210052023-12-13 12:50:20 +0800
commita37074aafa31be9341cb33542313b7a63db3ecb0 (patch)
treec29a1c19105744016b9b6b5040c7a2a5523b1590
parent8ae6f65c119fd8a532224cce6a8fbd2b70b37e18 (diff)
downloadaur-a37074aafa31be9341cb33542313b7a63db3ecb0.tar.gz
fix errors
-rw-r--r--.SRCINFO8
-rw-r--r--PKGBUILD19
-rw-r--r--spark-wallet.sh17
3 files changed, 26 insertions, 18 deletions
diff --git a/.SRCINFO b/.SRCINFO
index a6b2b39a7f56..ad8192d620fe 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,18 +1,18 @@
pkgbase = spark-wallet-bin
pkgdesc = A minimalistic wallet GUI for c-lightning, accessible over the web or through mobile and desktop apps.
pkgver = 0.3.1
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/shesek/spark-wallet
arch = x86_64
license = MIT
- depends = bash
depends = electron13
+ provides = spark-wallet-0.3.1
conflicts = spark-wallet
source = spark-wallet-0.3.1.deb::https://github.com/shesek/spark-wallet/releases/download/v0.3.1/spark-wallet-0.3.1-linux-amd64.deb
- source = LICENSE::https://raw.githubusercontent.com/shesek/spark-wallet/v0.3.1/LICENSE
+ source = LICENSE-0.3.1::https://raw.githubusercontent.com/shesek/spark-wallet/v0.3.1/LICENSE
source = spark-wallet.sh
sha256sums = 074554cbccbf2af7d804272bdb1dee0e266ce8ef5157973996876ff49022fe32
sha256sums = d8a82e79466ba5d679ba7edf5acd05bf6767edeb56f51a76ce8e121c7c887bf2
- sha256sums = 3412cda660ea2783505bbe089ab3ac70e50d279aa22130d1b88a3372e3b22843
+ sha256sums = 8915ca75d453698df81f7f3305cce6869f4261d754d90f0c3724b73c7b24ca84
pkgname = spark-wallet-bin
diff --git a/PKGBUILD b/PKGBUILD
index c98638bf50b8..c1312d1cbc20 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,25 +3,30 @@ _appname=spark
pkgname="${_appname}-wallet-bin"
_pkgname=Spark
pkgver=0.3.1
-pkgrel=1
+_electronversion=13
+pkgrel=2
pkgdesc="A minimalistic wallet GUI for c-lightning, accessible over the web or through mobile and desktop apps."
arch=('x86_64')
url="https://github.com/shesek/spark-wallet"
license=('MIT')
+conflicts=("${pkgname%-bin}")
+provides=("${pkgname%-bin}-${pkgver}")
depends=(
- 'bash'
- 'electron13'
+ "electron${_electronversion}"
)
-conflicts=("${pkgname%-bin}")
source=(
"${pkgname%-bin}-${pkgver}.deb::${url}/releases/download/v${pkgver}/${pkgname%-bin}-${pkgver}-linux-amd64.deb"
- "LICENSE::https://raw.githubusercontent.com/shesek/spark-wallet/v${pkgver}/LICENSE"
+ "LICENSE-${pkgver}::https://raw.githubusercontent.com/shesek/spark-wallet/v${pkgver}/LICENSE"
"${pkgname%-bin}.sh"
)
sha256sums=('074554cbccbf2af7d804272bdb1dee0e266ce8ef5157973996876ff49022fe32'
'd8a82e79466ba5d679ba7edf5acd05bf6767edeb56f51a76ce8e121c7c887bf2'
- '3412cda660ea2783505bbe089ab3ac70e50d279aa22130d1b88a3372e3b22843')
+ '8915ca75d453698df81f7f3305cce6869f4261d754d90f0c3724b73c7b24ca84')
build() {
+ sed -e "s|@electronversion@|${_electronversion}|" \
+ -e "s|@appname@|${pkgname%-bin}|g" \
+ -e "s|@appasar@|app.asar|g" \
+ -i "${srcdir}/${pkgname%-bin}.sh"
bsdtar -xf "${srcdir}/data.tar.xz"
sed "s|/opt/${_pkgname}/${_appname}-desktop %U|${pkgname%-bin}|g" -i "${srcdir}/usr/share/applications/${_appname}-desktop.desktop"
}
@@ -31,5 +36,5 @@ package() {
install -Dm644 "${srcdir}/opt/${_pkgname}/swiftshader/"* -t "${pkgdir}/usr/lib/${pkgname%-bin}/swiftshader"
install -Dm6444 "${srcdir}/usr/share/applications/${_appname}-desktop.desktop" "${pkgdir}/usr/share/applications/${pkgname%-bin}.desktop"
install -Dm644 "${srcdir}/usr/share/icons/hicolor/0x0/apps/${_appname}-desktop.png" "${pkgdir}/usr/share/pixmaps/${pkgname%-bin}.png"
- install -Dm644 "${srcdir}/LICENSE" -t "${pkgdir}/usr/share/licenses/${pkgname}"
+ install -Dm644 "${srcdir}/LICENSE-${pkgver}" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
} \ No newline at end of file
diff --git a/spark-wallet.sh b/spark-wallet.sh
index 566c27635d73..2ec4412e5c4f 100644
--- a/spark-wallet.sh
+++ b/spark-wallet.sh
@@ -1,11 +1,14 @@
#!/bin/bash
-_ELECTRON=/usr/bin/electron13
-APPDIR="/usr/lib/spark-wallet"
-export PATH="${APPDIR}:${PATH}"
-export LD_LIBRARY_PATH="${APPDIR}/swiftshader:${APPDIR}/lib:${LD_LIBRARY_PATH}"
-_ASAR="${APPDIR}/app.asar"
+set -e
+_APPDIR="/usr/lib/@appname@"
+export PATH="${_APPDIR}:${PATH}"
+export ELECTRON_IS_DEV=0
+export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}"
+_ASAR="${_APPDIR}/@appasar@"
if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then
- exec ${_ELECTRON} ${_ASAR} "$@"
+ cd "${_APPDIR}"
+ exec electron@electronversion@ "${_ASAR}" "$@"
else
- exec ${_ELECTRON} ${_ASAR} --no-sandbox "$@"
+ cd "${_APPDIR}"
+ exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@"
fi \ No newline at end of file