summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorblooser2019-01-12 14:02:09 +0100
committerblooser2019-01-12 14:02:09 +0100
commitece6271006ea8192294b41940e6ca1f917fdb431 (patch)
treeb47870f9f8ffd072473de37deff00fa96e5097ac
parente87388fb2c753865b6ec77170499161b4e8846a2 (diff)
downloadaur-ece6271006ea8192294b41940e6ca1f917fdb431.tar.gz
Take care if alias exist
Signed-off-by: blooser <Blooser@protonmail.com>
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD16
2 files changed, 10 insertions, 8 deletions
diff --git a/.SRCINFO b/.SRCINFO
index cf47a7a1619c..c2295c9c07c2 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = taurus
pkgdesc = GUI port scanner
pkgver = 1.2
- pkgrel = 3
+ pkgrel = 4
url = https://github.com/blooser/taurus
arch = x86_64
license = MIT
diff --git a/PKGBUILD b/PKGBUILD
index 1963e2a84b46..5cd455c3aad6 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,7 +1,7 @@
# Maintainer: Blooser <blooser@protonmail.com>
pkgname=taurus
pkgver=1.2
-pkgrel=3
+pkgrel=4
pkgdesc="GUI port scanner"
arch=('x86_64')
md5sums=('956971bed1cdb1953bd6344162177804')
@@ -38,13 +38,15 @@ package() {
mv $pkgname-$pkgver $pkgname
cp -r $pkgname ~/Documents
rm -rf $pkgname
- if [ ! -f ~/.local/share/applications ]; then
+ if [ -f ~/.local/share/applications ]; then
mkdir ~/.local/share/applications
fi
echo "${shortcut}" > ~/.local/share/applications/taurus.desktop
- if [ -f ~/.zshrc ]; then
- echo "alias taurus=${applocation}/taurus" >> ~/.zshrc
- else
- echo "alias taurus=${applocation}/taurus" >> ~/.bashrc
- fi
+ if type "taurus" > /dev/null; then
+ if [ -f ~/.zshrc ]; then
+ echo "alias taurus=${applocation}/taurus" >> ~/.zshrc
+ else
+ echo "alias taurus=${applocation}/taurus" >> ~/.bashrc
+ fi
+ fi
}