summaryrefslogtreecommitdiff
path: root/context/data/textadept/context/textadept-context.sh
diff options
context:
space:
mode:
Diffstat (limited to 'context/data/textadept/context/textadept-context.sh')
-rw-r--r--context/data/textadept/context/textadept-context.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/context/data/textadept/context/textadept-context.sh b/context/data/textadept/context/textadept-context.sh
new file mode 100644
index 000000000..5f613ccf8
--- /dev/null
+++ b/context/data/textadept/context/textadept-context.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+# copied from setuptex
+
+if [ z"$BASH_SOURCE" != z ]; then
+ textadept -u $(cd -P -- "$(dirname -- "$BASH_SOURCE")" && pwd -P) "$@" &
+elif [ z"$KSH_VERSION" != z ]; then
+ textadept -u $(cd -P -- "$(dirname -- "${.sh.file}")" && pwd -P) "$@" &
+else
+ textadept -u $(cd -P -- "$(dirname -- "$0")" && pwd -P) "$@" &
+fi
+