Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mcint/b90bb571fd1a987507cf to your computer and use it in GitHub Desktop.
Save mcint/b90bb571fd1a987507cf to your computer and use it in GitHub Desktop.
if [[ "$PATH" =~ "%" ]]; then
PATH="$((for SUB in $(echo $PATH | tr : '\n'); do [[ \"$SUB\" =~ \"%\" ]] && (echo \"$(printenv `echo $SUB|cut -d% -f2`)$(echo $SUB|cut -d% -f3)\" | sed 's_C:_/c_g' | sed 's_\\_/_g') || echo $SUB; done) | tr '\n' : | sed 's_:$__')"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment