diff options
author | blocklisted | 2022-01-02 21:58:47 +0100 |
---|---|---|
committer | BlockListed | 2022-01-02 22:01:48 +0100 |
commit | f81636f4ab79919f2e6b842e94ae302210dbe1bb (patch) | |
tree | 0525af8b58bd08f1fd510a9c79e9bf3fc9fb6647 | |
download | aur-f81636f4ab79919f2e6b842e94ae302210dbe1bb.tar.gz |
finished initial creation and testing
-rw-r--r-- | .SRCINFO | 17 | ||||
-rw-r--r-- | PKGBUILD | 21 | ||||
-rw-r--r-- | windscribe-v2-bin.install | 42 |
3 files changed, 80 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..fec6dc140253 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,17 @@ +pkgbase = windscribe-v2-bin + pkgdesc = Windscribe GUI tool for Linux + pkgver = 2.3.15_beta + pkgrel = 1 + url = https://windscribe.com/guides/linux + install = windscribe-v2-bin.install + arch = x86_64 + license = GPL2 + depends = bash + depends = nftables + provides = windscribe + conflicts = windscribe-cli + options = !strip + source = https://deploy-do.windscribe.com/apps/windscribe_2.3.15_beta_amd64.deb + sha1sums = 64f065ce1ee991f8af424673275e9eb9c2b30e86 + +pkgname = windscribe-v2-bin diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..ae28e1238df1 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,21 @@ +# Maintainer: blocklisted <blocklisted at protonmail dot com> +pkgname=windscribe-v2-bin +pkgver=2.3.15_beta +pkgrel=1 +pkgdesc="Windscribe GUI tool for Linux" +arch=('x86_64') +url="https://windscribe.com/guides/linux" +license=('GPL2') +depends=('bash' 'nftables') +provides=('windscribe') +conflicts=('windscribe-cli') +options=('!strip') +install=windscribe-v2-bin.install +source=("https://deploy-do.windscribe.com/apps/windscribe_${pkgver}_amd64.deb") +sha1sums=('64f065ce1ee991f8af424673275e9eb9c2b30e86') + +package() { + bsdtar -C "${pkgdir}" -xJf data.tar.xz + + chmod -R 755 ${pkgdir} +}
\ No newline at end of file diff --git a/windscribe-v2-bin.install b/windscribe-v2-bin.install new file mode 100644 index 000000000000..a775971fe510 --- /dev/null +++ b/windscribe-v2-bin.install @@ -0,0 +1,42 @@ +pre_install() { + end=$((SECONDS+10)) + + while : + do + if [ -z "$(ps -eo args | grep WindscribeEngine | grep -v grep)" ]; then + break + fi + + if [ $SECONDS -gt $end ]; then + echo 'Error during Windscribe installation. WindscribeEngine is running. Please re-launch Windscribe. And try to update again.' + exit 1 + fi + done + + systemctl stop windscribe-helper > /dev/null 2>&1 + systemctl disable windscribe-helper > /dev/null 2>&1 + + # Stop and disable firewalld service if it is active, otherwise it will conflict with iptables on OS reboot + # Relevant for Fedora distributions + systemctl is-active --quiet firewalld + if [ $? -eq 0 ] + then + echo "Firewalld service is running. It will be stopped and disabled to avoid conflicts with the Windscribe iptables firewall." + sudo systemctl stop firewalld + sudo systemctl disable firewalld + fi + + echo "Finish pre-install script" +} + +post_install() { + set -e + systemctl enable windscribe-helper + systemctl start windscribe-helper +} + +pre_remove() { + set -e + systemctl stop windscribe-helper + systemctl disable windscribe-helper +} |