Cygwin convert windows path to linux path: Difference between revisions
Jump to navigation
Jump to search
(Created page with "Using [http://cygwin-lite.sourceforge.net/html/cygpath.html Cygwin Utilities: cygpath] to convert windows path ↔ to linux path == convert windows path to linux path == <pre...") |
No edit summary |
||
| Line 1: | Line 1: | ||
Using [http://cygwin-lite.sourceforge.net/html/cygpath.html Cygwin Utilities: cygpath] to convert windows path ↔ to linux path | Using [http://cygwin-lite.sourceforge.net/html/cygpath.html Cygwin Utilities: cygpath] to convert windows path ↔ to linux path | ||
== steps == | |||
# launch [https://www.cygwin.com/ cygwin] | |||
# input the following commands after $ symbol | |||
== convert windows path to linux path == | == convert windows path to linux path == | ||
Revision as of 14:17, 21 April 2016
Using Cygwin Utilities: cygpath to convert windows path ↔ to linux path
steps
- launch cygwin
- input the following commands after $ symbol
convert windows path to linux path
$ cygpath -u 'c:\Users\User\Desktop\' /cygdrive/c/Users/User/Desktop/ $ cygpath -u c:\Program Files\ met error, press ctrl+c to escape enclose the whole path with single quote symbol if the path contains white space characters $ cygpath -u 'c:\Program Files\' /cygdrive/c/Program Files/
switch to the specified path
$ cd "$(cygpath -u 'c:\Program Files\')" $ pwd /cygdrive/c/Program Files
convert linux path to windows path
$ cygpath -w '/cygdrive/c/Program Files/' c:\Program Files\