summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Parrish2018-07-19 14:53:32 -0400
committerDavid Parrish2018-07-19 14:53:32 -0400
commitbda2c9b81c99dd4a782a7872a99d2326bc1c05e6 (patch)
treec3130b61c89f6d3beb88b3e8276a11f6204148dd
downloadaur-bda2c9b81c99dd4a782a7872a99d2326bc1c05e6.tar.gz
Initial commit
-rw-r--r--.SRCINFO18
-rw-r--r--PKGBUILD45
-rw-r--r--zap-desktop-git.install14
-rw-r--r--zap-desktop.desktop8
4 files changed, 85 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..72543b5ae6fd
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,18 @@
+# Generated by mksrcinfo v8
+# Thu Jul 19 18:50:15 UTC 2018
+pkgbase = zap-desktop-git
+ pkgdesc = Lightning wallet focused on user experience and ease of use
+ pkgver = 0.1.1.beta.513.gf97ffa2
+ pkgrel = 1
+ url = https://github.com/LN-Zap/zap-desktop
+ install = zap-desktop-git.install
+ arch = x86_64
+ license = MIT
+ depends = lnd
+ source = zap-desktop-git::git+https://github.com/LN-Zap/zap-desktop.git
+ source = zap-desktop.desktop
+ sha256sums = SKIP
+ sha256sums = 8c7a0940cced4e02b9d4dc1e2ca98f546117a079f37b91739ef70a321f86d5ee
+
+pkgname = zap-desktop-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..d7980f2bb6cc
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,45 @@
+# Maintainer: David Parrish <daveparrish@tutanota.com>
+
+pkgname=zap-desktop-git
+pkgver=0.1.1.beta.513.gf97ffa2
+pkgrel=1
+pkgdesc="Lightning wallet focused on user experience and ease of use"
+arch=('x86_64')
+url="https://github.com/LN-Zap/zap-desktop"
+license=('MIT')
+depends=('lnd')
+install="$pkgname.install"
+source=("$pkgname::git+https://github.com/LN-Zap/zap-desktop.git"
+ "zap-desktop.desktop")
+sha256sums=('SKIP'
+ '8c7a0940cced4e02b9d4dc1e2ca98f546117a079f37b91739ef70a321f86d5ee')
+
+pkgver() {
+ cd "$pkgname" || exit
+ git describe --tags | sed 's/^v//;s/-/./g'
+}
+
+build() {
+ cd "$pkgname" || exit
+ yarn
+ npm run package-linux
+}
+
+package() {
+ install -d "$pkgdir"/{opt/,usr/bin/,usr/share/applications,/usr/share/pixmaps,/usr/share/licenses/$pkgname}
+
+ # Install all .deb files into /opt.
+ mkdir "$pkgdir/opt/$pkgname"
+ cp -r "$srcdir/$pkgname/release/linux-unpacked/". "$pkgdir/opt/$pkgname"
+
+ # Symlink executable
+ ln -s "/opt/$pkgname/zap-desktop" "$pkgdir/usr/bin/zap-desktop"
+
+ # Symlink licenses
+ ln -s "/opt/$pkgname/LICENSES.electron.txt" "$pkgdir/usr/share/licenses/$pkgname"
+ ln -s "/opt/$pkgname/LICENSES.chromium.html" "$pkgdir/usr/share/licenses/$pkgname"
+
+ # Desktop icon
+ install -D -m644 "$srcdir/zap-desktop.desktop" "${pkgdir}/usr/share/applications/zap-desktop.desktop"
+ install -D -m644 "$srcdir/$pkgname/resources/icon.png" "${pkgdir}/usr/share/pixmaps/zap-desktop.png"
+}
diff --git a/zap-desktop-git.install b/zap-desktop-git.install
new file mode 100644
index 000000000000..03fc49718a15
--- /dev/null
+++ b/zap-desktop-git.install
@@ -0,0 +1,14 @@
+# arg 1: the new package version
+post_install() {
+ echo "Creating LND symlink"
+ lnd_path=$(command -v lnd)
+ mkdir -p "/opt/zap-desktop-git/resources/bin"
+ ln -s "$lnd_path" "/opt/zap-desktop-git/resources/bin/lnd"
+}
+
+# arg 1: the old package version
+pre_remove() {
+ echo "Removing LND symlink"
+ rm "opt/zap-desktop-git/resources/bin/lnd"
+ rmdir "/opt/zap-desktop-git/resources/bin"
+}
diff --git a/zap-desktop.desktop b/zap-desktop.desktop
new file mode 100644
index 000000000000..59eefa526a4d
--- /dev/null
+++ b/zap-desktop.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Type=Application
+Name=Zap Desktop
+GenericName=Lightning network desktop wallet
+Exec=zap-desktop %u
+Icon=zap-desktop
+Categories=Utility;Finance;
+Keywords=internet;