summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorzxp198210052023-12-05 10:52:51 +0800
committerzxp198210052023-12-05 10:52:51 +0800
commitba4899c7c4110534a0e2fa3d8fd2db701e4b8461 (patch)
tree8d12390ded5e17dcee9bf32168be4b20e69889f0
parentf98ed8f7b9d626944dd7524cb55527af9b64f08b (diff)
downloadaur-ba4899c7c4110534a0e2fa3d8fd2db701e4b8461.tar.gz
update to 2.8.0
-rw-r--r--.SRCINFO14
-rw-r--r--PKGBUILD14
-rw-r--r--leafview.sh17
3 files changed, 25 insertions, 20 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 5aec17ad24d1..c83de25d2a2b 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,19 +1,19 @@
pkgbase = leafview-bin
pkgdesc = A minimalist image viewer based on Leaflet.js and Electron.
- pkgver = 2.7.10
+ pkgver = 2.8.0
pkgrel = 1
url = https://github.com/sprout2000/leafview
arch = x86_64
license = MIT
- depends = electron27
+ depends = electron28
depends = hicolor-icon-theme
- provides = leafview=2.7.10
+ provides = leafview=2.8.0
conflicts = leafview
- source = leafview-2.7.10.deb::https://github.com/sprout2000/leafview/releases/download/v2.7.10/LeafView-2.7.10-linux-amd64.deb
- source = LICENSE-2.7.10.md::https://raw.githubusercontent.com/sprout2000/leafview/v2.7.10/LICENSE.md
+ source = leafview-2.8.0.deb::https://github.com/sprout2000/leafview/releases/download/v2.8.0/LeafView-2.8.0-linux-amd64.deb
+ source = LICENSE-2.8.0.md::https://raw.githubusercontent.com/sprout2000/leafview/v2.8.0/LICENSE.md
source = leafview.sh
- sha256sums = 5dcdc3c69060097f5512bacd5f3a43ae141fc91a3ca4840c2db37c1230360a0f
+ sha256sums = ef211546ccc2f7b417f59703439cfa7491c0326dc73593b680ec7d888d7da2be
sha256sums = b68f9bc26df0993fe2680014cb2f0c968a910071d496be05fe040ebeaac84961
- sha256sums = bbe689b1e71b8633845f692e864065bcbda67cf7b5f1355fc98ffef5f6d9d571
+ sha256sums = 8915ca75d453698df81f7f3305cce6869f4261d754d90f0c3724b73c7b24ca84
pkgname = leafview-bin
diff --git a/PKGBUILD b/PKGBUILD
index 0264c6de59d3..f1b686f0dd4d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,7 +1,8 @@
# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
pkgname=leafview-bin
_pkgname=LeafView
-pkgver=2.7.10
+pkgver=2.8.0
+_electronversion=28
pkgrel=1
pkgdesc="A minimalist image viewer based on Leaflet.js and Electron."
arch=("x86_64")
@@ -10,7 +11,7 @@ license=('MIT')
provides=("${pkgname%-bin}=${pkgver}")
conflicts=("${pkgname%-bin}")
depends=(
- 'electron27'
+ "electron${_electronversion}"
'hicolor-icon-theme'
)
source=(
@@ -18,11 +19,14 @@ source=(
"LICENSE-${pkgver}.md::https://raw.githubusercontent.com/sprout2000/leafview/v${pkgver}/LICENSE.md"
"${pkgname%-bin}.sh"
)
-sha256sums=('5dcdc3c69060097f5512bacd5f3a43ae141fc91a3ca4840c2db37c1230360a0f'
+sha256sums=('ef211546ccc2f7b417f59703439cfa7491c0326dc73593b680ec7d888d7da2be'
'b68f9bc26df0993fe2680014cb2f0c968a910071d496be05fe040ebeaac84961'
- 'bbe689b1e71b8633845f692e864065bcbda67cf7b5f1355fc98ffef5f6d9d571')
+ '8915ca75d453698df81f7f3305cce6869f4261d754d90f0c3724b73c7b24ca84')
build() {
- sed -i "s|@electronversion@|${_electronversion}|" "$srcdir/${pkgname%-bin}.sh"
+ 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}/${pkgname%-bin} %U|${pkgname%-bin}|g" -i "${srcdir}/usr/share/applications/${pkgname%-bin}.desktop"
}
diff --git a/leafview.sh b/leafview.sh
index 8d1637a9afd5..2ec4412e5c4f 100644
--- a/leafview.sh
+++ b/leafview.sh
@@ -1,13 +1,14 @@
#!/bin/bash
-APPDIR="/usr/lib/leafview"
-export PATH="${APPDIR}:${PATH}"
+set -e
+_APPDIR="/usr/lib/@appname@"
+export PATH="${_APPDIR}:${PATH}"
export ELECTRON_IS_DEV=0
-#export LD_LIBRARY_PATH="${APPDIR}/lib:${LD_LIBRARY_PATH}"
-_ASAR="${APPDIR}/app.asar"
+export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}"
+_ASAR="${_APPDIR}/@appasar@"
if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then
- cd $APPDIR
- exec electron@electronversion@ ${_ASAR} "$@"
+ cd "${_APPDIR}"
+ exec electron@electronversion@ "${_ASAR}" "$@"
else
- cd $APPDIR
- exec electron@electronversion@ ${_ASAR} --no-sandbox "$@"
+ cd "${_APPDIR}"
+ exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@"
fi \ No newline at end of file