summaryrefslogtreecommitdiffstats
path: root/src/testApp.sh
diff options
context:
space:
mode:
authorSebastian Schmelzer2011-01-27 16:47:34 +0100
committerSebastian Schmelzer2011-01-27 16:47:34 +0100
commita7bba9f38c92c3c9deaeaf2cd0e1b68e3ef1b98d (patch)
tree5e58a98a7e9a2c9e639cfabbbb998435d925fe86 /src/testApp.sh
parentrenaming, little things.. (diff)
downloadfbgui-a7bba9f38c92c3c9deaeaf2cd0e1b68e3ef1b98d.tar.gz
fbgui-a7bba9f38c92c3c9deaeaf2cd0e1b68e3ef1b98d.tar.xz
fbgui-a7bba9f38c92c3c9deaeaf2cd0e1b68e3ef1b98d.zip
remove absolute path from test script ..
Diffstat (limited to 'src/testApp.sh')
-rwxr-xr-xsrc/testApp.sh8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/testApp.sh b/src/testApp.sh
index a34c653..ccd7cd6 100755
--- a/src/testApp.sh
+++ b/src/testApp.sh
@@ -4,13 +4,19 @@ if [ $# = 0 ]; then
echo "No URL passed, exiting..."
exit
fi
+
+script_path="$(cd "${0%/*}" 2>/dev/null; echo "$PWD"/"${0##*/}")"
+
+# to get the path only - not the script name - add
+working_path=`dirname "$script_path"`
+
# Start QT's virtual framebuffer
/usr/local/Trolltech/Qt-4.7.1/bin/qvfb -width 800 -height 600 &
# Wait for it to load (needed?)
sleep 1
# Start the fbbrowser app.
# This requires the fbgui git repository to be in the user's home directory.
-~/fbgui/src/fbgui -qws $1
+$working_path/fbgui -qws $1
# Check if fbbrowser is not running, if so kill the qvfb.
if [ $(ps aux | grep -v grep | grep -c fbgui) -eq 1 ]
then