summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xqtc19
1 files changed, 19 insertions, 0 deletions
diff --git a/qtc b/qtc
new file mode 100755
index 000000000000..60298570a26f
--- /dev/null
+++ b/qtc
@@ -0,0 +1,19 @@
+#!/usr/bin/env bash
+
+if [[ "$(uname -s)" = "Darwin" ]]; then
+ open -a "Qt Creator" $@
+else
+ pid=$(pidof qtcreator-bin)
+
+ # find existing creator instance
+ if [[ "${pid}" != "" ]]; then
+ creatorbin=$(ls -l /proc/${pid}/exe | awk '{ print $11 }')
+ ${creatorbin} -client $@
+ exit 0
+ fi
+
+ # failing that run the creator in your path
+ qtcreator.sh $@
+fi
+
+exit 0