From 1d3883b1abed6e6035c89f1a67420ec9455c7b8a Mon Sep 17 00:00:00 2001 From: adamcruz Date: Wed, 9 May 2018 17:18:34 +0800 Subject: [PATCH] Added install.sh --- install.sh | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 install.sh diff --git a/install.sh b/install.sh new file mode 100644 index 0000000..97c50c4 --- /dev/null +++ b/install.sh @@ -0,0 +1,35 @@ +#!/bin/bash + +cd /opt + +# Get Latest GitKraken +wget https://release.gitkraken.com/linux/gitkraken-amd64.tar.gz + +# Extract +tar -xvzf gitkraken-amd64.tar.gz + +# Remove tar.gz +rm gitkraken-amd64.tar.gz + +# Add gitkraken to PATH +echo "export PATH=\$PATH:/opt/gitkraken" >> ~/.bashrc +source ~/.bashrc + +# Download gitkraken launcher icon +wget https://git.spectre5.com/adamcruz/install-gitkraken/raw/commit/e829f20289e0761e8b98bd5d86d36a4b4b0e24d0/gitkraken_logo.png +mv gitkraken_logo.png ./gitkraken/icon.png + +# Create desktop entry +sudo touch /usr/share/applications/gitkraken.desktop + +# copy the following contents into gitkraken.desktop file: +echo " +[Desktop Entry] +Name=GitKraken +Comment=Git Flow +Exec=/opt/gitkraken/gitkraken +Icon=/opt/gitkraken/icon.png +Terminal=false +Type=Application +Encoding=UTF-8 +Categories=Utility;Development;" | sudo tee -a /usr/share/applications/gitkraken.desktop >/dev/null \ No newline at end of file