Skip to content

Commit

Permalink
Merge pull request #149 from carhartl/fix-oldpwd
Browse files Browse the repository at this point in the history
Fix init function to leave $OLDPWD intact
  • Loading branch information
dasJ authored Nov 11, 2016
2 parents 7eb70ec + db52009 commit 6c55ec3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ autoenv_init() {
_mountpoint="`df "${PWD}" | awk 'END{print $NF}'`"
# Remove double slashes, see #125
_pwd="`echo "${PWD}" | sed "${_sedregexp}" 's:/+:/:g'`"
command -v chdir >/dev/null 2>&1 && \chdir "${_pwd}" || builtin cd "${_pwd}"
# Discover all files we need to source
# We do this in a subshell so we can cd/chdir
_files="`
command -v chdir >/dev/null 2>&1 && \chdir "${_pwd}" || builtin cd "${_pwd}"
_hadone=''
while :; do
_file="$(pwd -P)/${AUTOENV_ENV_FILENAME}"
Expand Down

0 comments on commit 6c55ec3

Please sign in to comment.