Returns the real, canonical case of a path.
Resolve-PathCase [-Path] <String> [<CommonParameters>]
The .NET and Windows path/file system APIs respect and preserve the case of paths passed to them. This function will return the actual case of a path on the file system, regardless of the case of the string passed in.
If the path doesn't an exist, an error is written and nothing is returned.
Name | Type | Description | Required? | Pipeline Input | Default Value |
---|---|---|---|---|---|
Path | String | The path whose real, canonical case should be returned. |
true | true (ByPropertyName) |
Resolve-PathCase -Path "C:\WINDOWS\SYSTEM32"
Returns C:\Windows\system32
.
Resolve-PathCase -Path 'c:\projects\carbon'
Returns C:\Projects\Carbon
.