From 62d27bf9674a7865913c8f0eabd8f43fe18026b5 Mon Sep 17 00:00:00 2001 From: ADAM David Alan Martin Date: Fri, 31 Jan 2014 11:19:23 -0500 Subject: [PATCH] Added original path check/sourcing. Seems to not work. :-/ Requires tcshrc resource alias to change to startup hooks. --- startup_hooks/tcshrc | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/startup_hooks/tcshrc b/startup_hooks/tcshrc index 4f3925c..03656bc 100644 --- a/startup_hooks/tcshrc +++ b/startup_hooks/tcshrc @@ -39,6 +39,15 @@ if( -c `tty` ) then if( $?CSHENV_DEBUG ) then echo "Going to source core tcshrc..." endif + + # Capture the original path, so that we don't + # keep infinitely expanding it. + if( $?CSHENV_ORIGINAL_PATH ) then + setenv PATH ${CSHENV_ORIGINAL_PATH} + else + setenv CSHENV_ORIGINAL_PATH ${PATH} + endif + source ${CSHENV_DIR}/tcshrc endif