diff options
author | zxp19821005 | 2024-01-23 12:25:00 +0800 |
---|---|---|
committer | zxp19821005 | 2024-01-23 12:25:00 +0800 |
commit | 66372c660421fba8cc419ab07e61349c69469b64 (patch) | |
tree | fe692f8f728b990d4e8f64a73cbcc7a60f3519a2 | |
download | aur-66372c660421fba8cc419ab07e61349c69469b64.tar.gz |
update to 0.0.4
-rw-r--r-- | .SRCINFO | 20 | ||||
-rw-r--r-- | PKGBUILD | 39 | ||||
-rw-r--r-- | cubytext.sh | 15 |
3 files changed, 74 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..9034cdef74dd --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,20 @@ +pkgbase = cubytext-bin + pkgdesc = An open-source knowledge management app. + pkgver = 0.0.4 + pkgrel = 1 + url = https://github.com/vincentdchan/CubyText + arch = x86_64 + license = MIT + depends = electron19 + depends = nodejs + provides = cubytext=0.0.4 + conflicts = cubytext + options = !strip + source = cubytext-0.0.4.deb::https://github.com/vincentdchan/CubyText/releases/download/0.0.4/cubytext_0.0.4_amd64.deb + source = LICENSE-0.0.4::https://raw.githubusercontent.com/vincentdchan/CubyText/0.0.4/LICENSE.txt + source = cubytext.sh + sha256sums = bd0ff4fdbbeaa30ab532d7efb00b7dc9962eaa87826fa7ee80727cf518a36566 + sha256sums = db7050c50a29912ab18366ac4d340da6359df6e8ad1c31bc019af5b707a69aee + sha256sums = d4272fed78cdcacd9edfb019134ac485d65b43f4d8c7a4179edbaed56af9b231 + +pkgname = cubytext-bin diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..e7ce9e0fb735 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,39 @@ +# Maintainer: zxp19821005 <zxp19821005 at 163 dot com> +pkgname=cubytext-bin +pkgver=0.0.4 +_electronversion=19 +pkgrel=1 +pkgdesc="An open-source knowledge management app." +arch=('x86_64') +url="https://github.com/vincentdchan/CubyText" +license=('MIT') +provides=("${pkgname%-bin}=${pkgver}") +conflicts=("${pkgname%-bin}") +depends=( + "electron${_electronversion}" + 'nodejs' +) +options=('!strip') +source=( + "${pkgname%-bin}-${pkgver}.deb::${url}/releases/download/${pkgver}/${pkgname%-bin}_${pkgver}_amd64.deb" + "LICENSE-${pkgver}::https://raw.githubusercontent.com/vincentdchan/CubyText/${pkgver}/LICENSE.txt" + "${pkgname%-bin}.sh" +) +sha256sums=('bd0ff4fdbbeaa30ab532d7efb00b7dc9962eaa87826fa7ee80727cf518a36566' + 'db7050c50a29912ab18366ac4d340da6359df6e8ad1c31bc019af5b707a69aee' + 'd4272fed78cdcacd9edfb019134ac485d65b43f4d8c7a4179edbaed56af9b231') +build() { + sed -e "s|@electronversion@|${_electronversion}|g" \ + -e "s|@appname@|${pkgname%-bin}|g" \ + -e "s|@appasar@|app|g" \ + -i "${srcdir}/${pkgname%-bin}.sh" + bsdtar -xf "${srcdir}/data.tar.zst" +} +package() { + install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/usr/bin/${pkgname%-bin}" + install -Dm755 -d "${pkgdir}/usr/lib/${pkgname%-bin}" + cp -r "${srcdir}/usr/lib/${pkgname%-bin}/resources/app" "${pkgdir}/usr/lib/${pkgname%-bin}" + install -Dm644 "${srcdir}/usr/share/pixmaps/${pkgname%-bin}.png" -t "${pkgdir}/usr/share/pixmaps" + install -Dm644 "${srcdir}/usr/share/applications/${pkgname%-bin}.desktop" -t "${pkgdir}/usr/share/applications" + install -Dm644 "${srcdir}/LICENSE-${pkgver}" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" +}
\ No newline at end of file diff --git a/cubytext.sh b/cubytext.sh new file mode 100644 index 000000000000..aacd8f895847 --- /dev/null +++ b/cubytext.sh @@ -0,0 +1,15 @@ +#!/bin/sh +set -e +_APPDIR="/usr/lib/@appname@" +_ASAR="${_APPDIR}/@appasar@" +export PATH="${_APPDIR}:${PATH}" +export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}" +export ELECTRON_IS_DEV=0 +export NODE_ENV=production +cd "${_APPDIR}" +if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then + exec electron@electronversion@ "${_ASAR}" "$@" +else + exec electron@electronversion@ "${_ASAR}" --no-sandbox "$@" +fi +exit
\ No newline at end of file |