# HG changeset patch # User Jacob Dawid # Date 1327431452 -3600 # Node ID d19e3954c3152d6ef2ddd4e19b40bf59ee439d55 # Parent 4e6c717869f81918d8b88eb8ea00991e59e65469 Improved clone script for qterminal. *(get-qterminal.sh): Now pulling instead of cloning when directory exists. diff --git a/gui/get-qterminal.sh b/gui/get-qterminal.sh --- a/gui/get-qterminal.sh +++ b/gui/get-qterminal.sh @@ -1,6 +1,22 @@ -git clone https://code.google.com/p/qterminal/ -git checkout master -cd qterminal -qmake-qt4 qterminal.pro -make -cd .. +#!/bin/bash + +qterminal_dir="qterminal"; +echo "Updating qterminal.."; + +# Check whether we have already cloned the repository: +if [ -d $qterminal_dir ]; then + # Yes, so just pull any changes and rebuild. + cd qterminal + git pull + qmake-qt4 + cd .. +else + # No, clone the repository, checkout the stable branch + # and build it. + git clone https://code.google.com/p/qterminal/ + git checkout master + cd qterminal + qmake-qt4 qterminal.pro + make + cd .. +fi