diff options
author | surefire | 2018-03-26 00:09:09 +0300 |
---|---|---|
committer | surefire | 2018-03-26 00:11:16 +0300 |
commit | 191180fcf7dc9a5b3f240891389789d3ec99915d (patch) | |
tree | 7b8a6d4b1c856b9aa6c770936a9ce4fc804c2c02 | |
download | aur-191180fcf7dc9a5b3f240891389789d3ec99915d.tar.gz |
Initial
-rw-r--r-- | .SRCINFO | 22 | ||||
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 76 | ||||
-rw-r--r-- | sqlectron-gui.desktop | 9 | ||||
-rw-r--r-- | sqlectron-gui.sh | 3 |
5 files changed, 114 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..dbcc4b1c917c --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,22 @@ +pkgbase = sqlectron-gui-git + pkgdesc = A simple and lightweight SQL client with cross database and platform support + pkgver = 1.29.0+3+gd1eb407 + pkgrel = 1 + url = https://sqlectron.github.io/ + arch = x86_64 + license = MIT + makedepends = npm + makedepends = asar + makedepends = git + depends = electron + provides = sqlectron-gui + conflicts = sqlectron-gui + source = sqlectron-gui-git::git+https://github.com/sqlectron/sqlectron-gui.git + source = sqlectron-gui.sh + source = sqlectron-gui.desktop + sha1sums = SKIP + sha1sums = e0e7c83e47f368543a3c4505cf035d570e0d645b + sha1sums = b9fb3bc29a17dee5de9295e2fdb2b3025ed51d1f + +pkgname = sqlectron-gui-git + diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..c0f5825e28e5 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +*.pkg.tar.* +pkg/ +src/ +sqlectron-gui-git/ diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..623d60a0bd93 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,76 @@ +# Maintainer: surefire@cryptomile.net + +pkgname=sqlectron-gui-git +pkgver=1.29.0+3+gd1eb407 +pkgrel=1 +pkgdesc="A simple and lightweight SQL client with cross database and platform support" +arch=('x86_64') +url="https://sqlectron.github.io/" +license=('MIT') +depends=('electron') +makedepends=('npm' 'asar' 'git') +conflicts=('sqlectron-gui') +provides=('sqlectron-gui') +source=("${pkgname}::git+https://github.com/sqlectron/sqlectron-gui.git" + 'sqlectron-gui.sh' + 'sqlectron-gui.desktop') + +sha1sums=('SKIP' + 'e0e7c83e47f368543a3c4505cf035d570e0d645b' + 'b9fb3bc29a17dee5de9295e2fdb2b3025ed51d1f') + +pkgver() { + cd "${pkgname}" + git describe --tags --long | sed 's/-/+/g; s/^v//' +} + +prepare() { + cd "${pkgname}" + + # remove extra dependencies + sed -i package.json \ + -e '/"postinstall":/ d' \ + -e '/"electron":/ d' \ + -e '/"electron-builder":/ d' \ + -e '/"spawn-auto-restart":/ d' \ + -e '/"webpack-dev-middleware":/ d' \ + -e '/"webpack-dev-server":/ d' \ + -e '/"webpack-bundle-analyzer":/ s/,$//' +} + +build() { + cd "${pkgname}" + + npm install --build-from-source + npm run compile:browser + npm run compile:renderer + + mkdir app + mv -t ./app out + cp -t ./app package.json + + pushd app + npm install \ + --production \ + --build-from-source \ + --nodedir=/usr/lib/electron/node \ + --runtime=electron \ + --target=$(electron -v) \ + + popd + asar p app app.asar +} + +package() { + cd "${pkgname}" + + install -Dm0755 ../sqlectron-gui.sh "${pkgdir}/usr/bin/sqlectron-gui" + + install -Dm0644 build/app.png "${pkgdir}/usr/share/pixmaps/sqlectron-gui.png" + + install -Dm0644 -t "${pkgdir}/usr/lib/sqlectron-gui" app.asar + + install -Dm0644 -t "${pkgdir}/usr/share/applications" ../sqlectron-gui.desktop + + install -Dm0644 -t "${pkgdir}/usr/share/licenses/${pkgname}" LICENSE +} diff --git a/sqlectron-gui.desktop b/sqlectron-gui.desktop new file mode 100644 index 000000000000..0e5427603847 --- /dev/null +++ b/sqlectron-gui.desktop @@ -0,0 +1,9 @@ +[Desktop Entry] +Type=Application +Name=Sqlectron-gui +Comment=A simple and lightweight SQL client with cross database and platform support +Icon=sqlectron-gui +Exec=sqlectron-gui %U +Categories=Development;Utility; +StartupNotify=false +Terminal=false diff --git a/sqlectron-gui.sh b/sqlectron-gui.sh new file mode 100644 index 000000000000..c4a5ba8fe6c9 --- /dev/null +++ b/sqlectron-gui.sh @@ -0,0 +1,3 @@ +#!/usr/bin/sh + +exec electron /usr/lib/sqlectron-gui/app.asar "$@" |