diff options
author | zxp19821005 | 2024-03-29 18:08:21 +0800 |
---|---|---|
committer | zxp19821005 | 2024-03-29 18:08:21 +0800 |
commit | 874312710bbb487a453f2df93c19e18a5d3af216 (patch) | |
tree | 3d6e3c9d76bca254f939e06f83ae0a8c8aca16b1 | |
download | aur-874312710bbb487a453f2df93c19e18a5d3af216.tar.gz |
update to 1.19.6
-rw-r--r-- | .SRCINFO | 17 | ||||
-rw-r--r-- | PKGBUILD | 46 | ||||
-rw-r--r-- | etcher-ng.sh | 16 |
3 files changed, 79 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..5fa9972fc307 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,17 @@ +pkgbase = etcher-ng-bin + pkgdesc = Flash OS images to SD cards & USB drives, safely and easily - Custom, debloated + pkgver = 1.19.6 + pkgrel = 1 + url = https://github.com/Alex313031/etcher-ng + arch = x86_64 + license = Apache-2.0 + depends = electron22 + provides = etcher=1.19.6 + conflicts = etcher-ng + conflicts = etcher + source = etcher-ng-1.19.6.deb::https://github.com/Alex313031/etcher-ng/releases/download/v1.19.6/etcher-ng_1.19.6_amd64.deb + source = etcher-ng.sh + sha256sums = 70d85de455f49dc3c78511c03d5812548ba58d7d8659afc14c59f467f5ee1bbe + sha256sums = dc0c5ca385ad81a08315a91655c7c064b5bf110eada55e61265633ae198b39f8 + +pkgname = etcher-ng-bin diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..4b5b32269fd7 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,46 @@ +# Maintainer: zxp19821005 <zxp19821005 at 163 dot com> +_appname=etcher +pkgname="${_appname}-ng-bin" +_pkgname=Etcher-ng +pkgver=1.19.6 +_electronversion=22 +pkgrel=1 +pkgdesc="Flash OS images to SD cards & USB drives, safely and easily - Custom, debloated" +arch=('x86_64') +url="https://github.com/Alex313031/etcher-ng" +license=('Apache-2.0') +conflicts=( + "${pkgname%-bin}" + "${_appname}" +) +provides=("${_appname}=${pkgver}") +depends=( + "electron${_electronversion}" +) +source=( + "${pkgname%-bin}-${pkgver}.deb::${url}/releases/download/v${pkgver}/${pkgname%-bin}_${pkgver}_amd64.deb" + "${pkgname%-bin}.sh" +) +sha256sums=('70d85de455f49dc3c78511c03d5812548ba58d7d8659afc14c59f467f5ee1bbe' + 'dc0c5ca385ad81a08315a91655c7c064b5bf110eada55e61265633ae198b39f8') +build() { + sed -e "s|@electronversion@|${_electronversion}|" \ + -e "s|@appname@|${pkgname%-bin}|g" \ + -e "s|@runname@|app.asar|g" \ + -e "s|@options@||g" \ + -i "${srcdir}/${pkgname%-bin}.sh" + rm -rf "${srcdir}/"{opt,usr} + bsdtar -xf "${srcdir}/data."* + 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}" + install -Dm644 "${srcdir}/opt/${_pkgname}/resources/app.asar" -t "${pkgdir}/usr/lib/${pkgname%-bin}" + cp -r "${srcdir}/opt/${_pkgname}/resources/assets" "${pkgdir}/usr/lib/${pkgname%-bin}" + install -Dm644 "${srcdir}/opt/${_pkgname}/resources/"{"${_appname}-util",*.js} -t "${pkgdir}/usr/lib/${pkgname%-bin}" + install -Dm644 "${srcdir}/usr/share/applications/${pkgname%-bin}.desktop" -t "${pkgdir}/usr/share/applications" + for _icons in 16x16 24x24 32x32 48x48 64x64 96x96 128x128 144x144 256x256 512x512 1024x1024;do + install -Dm644 "${srcdir}/usr/share/icons/hicolor/${_icons}/apps/${pkgname%-bin}.png" \ + -t "${pkgdir}/usr/share/icons/hicolor/${_icons}/apps" + done +}
\ No newline at end of file diff --git a/etcher-ng.sh b/etcher-ng.sh new file mode 100644 index 000000000000..7ddcaab8d734 --- /dev/null +++ b/etcher-ng.sh @@ -0,0 +1,16 @@ +#!/bin/bash +set -e +_APPDIR="/usr/lib/@appname@" +_RUNNAME="${_APPDIR}/@runname@" +_OPTIONS="@options@" +export PATH="${_APPDIR}:${PATH}" +export LD_LIBRARY_PATH="${_APPDIR}/swiftshader:${_APPDIR}/lib:${LD_LIBRARY_PATH}" +export ELECTRON_IS_DEV=0 +export ELECTRON_FORCE_IS_PACKAGED=true +export NODE_ENV=production +cd "${_APPDIR}" +if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then + exec electron@electronversion@ "${_RUNNAME}" "${_OPTIONS}" "$@" || exit $? +else + exec electron@electronversion@ "${_RUNNAME}" "${_OPTIONS}" --no-sandbox "$@" || exit $? +fi
\ No newline at end of file |