-
-
Save tonidy/5280667 to your computer and use it in GitHub Desktop.
p2u is small script which convert windows path to unix path. It may useful in msys app when environment variable (contain path) set in Windows path.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # put this in .bashrc/.bash_profile file | |
| # the idea is taken from http://stackoverflow.com/a/13701495 | |
| # function to convert windows path to unix path | |
| # USAGE: p2u $WINDOWS_PATH | |
| p2u() { | |
| local winpath=$1 | |
| echo "/$winpath" | sed 's/\\/\//g' | sed 's/://' | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment