From 670ada11fdc76b1b83e8baf9a13e0ad2f154425d Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Tue, 14 Jan 2014 21:47:00 +0400 Subject: [PATCH] Get full path using cd/pwd and then cd back --- set-path | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/set-path b/set-path index b5051bc..5632504 100644 --- a/set-path +++ b/set-path @@ -1,5 +1,7 @@ -CWD="`dirname \"$0\"`" -CWD="`abspath.py \"$CWD\"`" +START_DIR="`pwd`" +cd "`dirname \"$0\"`" +CWD="`pwd`" +cd "$START_DIR" if echo "$PATH" | grep -vq "\(^\|:\)$CWD\(:\|$\)"; then PATH="$CWD:$PATH" fi -- 2.39.2