summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorzxp198210052023-07-07 16:06:37 +0800
committerzxp198210052023-07-07 16:06:37 +0800
commitc13200b6adaef202659788fa6c5c413a0c3929d1 (patch)
tree782492a09818d890e7f6d08efb71617f681c484a
downloadaur-c13200b6adaef202659788fa6c5c413a0c3929d1.tar.gz
first release
-rw-r--r--.SRCINFO21
-rw-r--r--PKGBUILD34
-rw-r--r--buttercup-desktop.sh6
3 files changed, 61 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..93d1facdbde1
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,21 @@
+pkgbase = buttercup-desktop-bin
+ pkgdesc = Cross-Platform Passwords & Secrets Vault
+ pkgver = 2.20.3
+ pkgrel = 1
+ url = https://buttercup.pw/
+ arch = aarch64
+ arch = armv7h
+ arch = x86_64
+ license = GPL3
+ depends = electron
+ depends = hicolor-icon-theme
+ source = buttercup-desktop.sh
+ sha256sums = a542d65f853688cde782a213642ef4c12d51734a28c314ea9ac993d7e9221344
+ source_aarch64 = buttercup-desktop-2.20.3-aarch64.AppImage::https://github.com/buttercup/buttercup-desktop/releases/download/v2.20.3/Buttercup-linux-arm64.AppImage
+ sha256sums_aarch64 = 76b885a9aae1a3f708f7202372b1c434a27d755275c24709d270f850dfca07e8
+ source_armv7h = buttercup-desktop-2.20.3-armv7h.AppImage::https://github.com/buttercup/buttercup-desktop/releases/download/v2.20.3/Buttercup-linux-armv7l.AppImage
+ sha256sums_armv7h = ab49db4be607384a38b5365f9d796ccb4a3b8387dec37e9b096dfabeb1de8ef8
+ source_x86_64 = buttercup-desktop-2.20.3-x86_64.AppImage::https://github.com/buttercup/buttercup-desktop/releases/download/v2.20.3/Buttercup-linux-x86_64.AppImage
+ sha256sums_x86_64 = 7bb0998c94a400090d9fbdd9ddc83e0f9494751781a7aa6acfbccaadb907b37f
+
+pkgname = buttercup-desktop-bin
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..5fdce17cfba3
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,34 @@
+# Maintainer: zxp19821005 <zxp19821005 at 163 dot com>
+pkgname=buttercup-desktop-bin
+pkgver=2.20.3
+pkgrel=1
+pkgdesc="Cross-Platform Passwords & Secrets Vault"
+arch=('aarch64' 'armv7h' 'x86_64')
+url="https://buttercup.pw/"
+_githuburl="https://github.com/buttercup/buttercup-desktop"
+license=('GPL3')
+conflits=("${pkgname%-bin}")
+depends=('electron' 'hicolor-icon-theme')
+source_aarch64=("${pkgname%-bin}-${pkgver}-aarch64.AppImage::${_githuburl}/releases/download/v${pkgver}/Buttercup-linux-arm64.AppImage")
+source_armv7h=("${pkgname%-bin}-${pkgver}-armv7h.AppImage::${_githuburl}/releases/download/v${pkgver}/Buttercup-linux-armv7l.AppImage")
+source_x86_64=("${pkgname%-bin}-${pkgver}-x86_64.AppImage::${_githuburl}/releases/download/v${pkgver}/Buttercup-linux-x86_64.AppImage")
+source=("${pkgname%-bin}.sh")
+sha256sums=('a542d65f853688cde782a213642ef4c12d51734a28c314ea9ac993d7e9221344')
+sha256sums_aarch64=('76b885a9aae1a3f708f7202372b1c434a27d755275c24709d270f850dfca07e8')
+sha256sums_armv7h=('ab49db4be607384a38b5365f9d796ccb4a3b8387dec37e9b096dfabeb1de8ef8')
+sha256sums_x86_64=('7bb0998c94a400090d9fbdd9ddc83e0f9494751781a7aa6acfbccaadb907b37f')
+prepare() {
+ chmod a+x "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage"
+ "${srcdir}/${pkgname%-bin}-${pkgver}-${CARCH}.AppImage" --appimage-extract > /dev/null
+}
+package() {
+ install -Dm755 "${srcdir}/${pkgname%-bin}.sh" "${pkgdir}/opt/${pkgname%-bin}/${pkgname%-bin}"
+ install -Dm644 "${srcdir}/squashfs-root/resources/app.asar" "${pkgdir}/opt/${pkgname%-bin}/${pkgname%-bin}.asar"
+ for _icons in 16x16 32x32 48x48 128x128 256x256;do
+ install -Dm644 "${srcdir}/squashfs-root/usr/share/icons/hicolor/${_icons}/apps/${pkgname%-desktop-bin}.png" \
+ "${pkgdir}/usr/share/icons/hicolor/${_icons}/apps/${pkgname%-bin}.png"
+ done
+ sed "s|AppRun --no-sandbox %U|/opt/${pkgname%-bin}/${pkgname%-bin}|g;s|Icon=${pkgname%-desktop-bin}|Icon=${pkgname%-bin}|g" \
+ -i "${srcdir}/squashfs-root/${pkgname%-desktop-bin}.desktop"
+ install -Dm644 "${srcdir}/squashfs-root/${pkgname%-desktop-bin}.desktop" "${pkgdir}/usr/share/applications/${pkgname%-bin}.desktop"
+} \ No newline at end of file
diff --git a/buttercup-desktop.sh b/buttercup-desktop.sh
new file mode 100644
index 000000000000..398a99db8acf
--- /dev/null
+++ b/buttercup-desktop.sh
@@ -0,0 +1,6 @@
+#!/bin/bash
+if [[ $EUID -ne 0 ]] || [[ $ELECTRON_RUN_AS_NODE ]]; then
+ exec electron /opt/buttercup-desktop/buttercup-desktop.asar "$@"
+else
+ exec electron --no-sandbox /opt/buttercup-desktop/buttercup-desktop.asar "$@"
+fi \ No newline at end of file