Created
March 4, 2018 23:46
-
-
Save mishrsud/eb58799e9a3fe5c35536ba46d73dc2d9 to your computer and use it in GitHub Desktop.
Converts a Windows path to Unix path that can be used from WSL (Windows Subsystem for Linux)
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
| var path = @"C:\SourceCode\docker-test-framework\Core\app.config"; | |
| var cdriveRepl = string.Concat("/", "mnt", "/", "c", "/"); | |
| var unixPathSep = "/"; | |
| Console.WriteLine(path.Replace(@"C:\", cdriveRepl).Replace(@"\", unixPathSep)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment