Skip to content

Commit 8636378

Browse files
kaizokuapenwarr
authored andcommitted
Dereference symlink for sshuttle launch script
(Modified slightly by apenwarr)
1 parent f5eed4c commit 8636378

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

sshuttle

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
#!/bin/sh
2-
DIR=$(dirname "$0")
2+
EXE=$0
3+
for i in 1 2 3 4 5 6 7 8 9 10; do
4+
[ -L "$EXE" ] || break
5+
EXE=$(readlink "$EXE")
6+
done
7+
DIR=$(dirname "$EXE")
38
if python2 -V 2>/dev/null; then
49
exec python2 "$DIR/main.py" python2 "$@"
510
else

0 commit comments

Comments
 (0)