summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorzxp198210052024-01-17 23:42:38 +0800
committerzxp198210052024-01-17 23:42:38 +0800
commit14d52cb98b279df4f19cc82771f90ca0218cac05 (patch)
tree8e24677beac24381e4f19cdf246bd14559cf9eef
parentf917f69657ee1c7c71305636f8dc59667014eefa (diff)
downloadaur-14d52cb98b279df4f19cc82771f90ca0218cac05.tar.gz
fix errors
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD4
-rw-r--r--knowte.sh13
3 files changed, 10 insertions, 9 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 92e4937f6956..814e33aced52 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -12,6 +12,6 @@ pkgbase = knowte-bin
source = knowte-3.0.0.pacman::https://github.com/digimezzo/knowte/releases/download/v3.0.0/Knowte-3.0.0.pacman
source = knowte.sh
sha256sums = 6f7ad45262020e24c66536d627442b27601109d434e0d5870de2d48519fe2750
- sha256sums = 8915ca75d453698df81f7f3305cce6869f4261d754d90f0c3724b73c7b24ca84
+ sha256sums = d4272fed78cdcacd9edfb019134ac485d65b43f4d8c7a4179edbaed56af9b231
pkgname = knowte-bin
diff --git a/PKGBUILD b/PKGBUILD
index dd1795c25eaf..e404272392a1 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -19,13 +19,13 @@ source=(
"${pkgname%-bin}.sh"
)
sha256sums=('6f7ad45262020e24c66536d627442b27601109d434e0d5870de2d48519fe2750'
- '8915ca75d453698df81f7f3305cce6869f4261d754d90f0c3724b73c7b24ca84')
+ 'd4272fed78cdcacd9edfb019134ac485d65b43f4d8c7a4179edbaed56af9b231')
build() {
sed -e "s|@electronversion@|${_electronversion}|" \
-e "s|@appname@|${pkgname%-bin}|g" \
-e "s|@appasar@|app.asar|g" \
-i "${srcdir}/${pkgname%-bin}.sh"
- sed "s|/opt/${_pkgname}/${pkgname%-bin} %U|${pkgname%-bin}|g" -i "${srcdir}/usr/share/applications/${pkgname%-bin}.desktop"
+ sed "s|/opt/${_pkgname}/${pkgname%-bin}|${pkgname%-bin}|g" -i "${srcdir}/usr/share/applications/${pkgname%-bin}.desktop"
}
package() {
install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/usr/bin/${pkgname%-bin}"
diff --git a/knowte.sh b/knowte.sh
index 2ec4412e5c4f..aacd8f895847 100644
--- a/knowte.sh
+++ b/knowte.sh
@@ -1,14 +1,15 @@
-#!/bin/bash
+#!/bin/sh
set -e
_APPDIR="/usr/lib/@appname@"
+_ASAR="${_APPDIR}/@appasar@"
export PATH="${_APPDIR}:${PATH}"
-export ELECTRON_IS_DEV=0
export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}"
-_ASAR="${_APPDIR}/@appasar@"
+export ELECTRON_IS_DEV=0
+export NODE_ENV=production
+cd "${_APPDIR}"
if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then
- cd "${_APPDIR}"
exec electron@electronversion@ "${_ASAR}" "$@"
else
- cd "${_APPDIR}"
exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@"
-fi \ No newline at end of file
+fi
+exit \ No newline at end of file