Notice the capitalization of NET. The actual on-disk layout for these SDKs contain instead Net. This capitalization change did not cause issues on Windows as that is a case-insensitive file system but did cause issues on other platforms which are case-sensitive. The experience of tracking down this issue was frustrating because a capitalization problem in a file path is not one that immediately jumps out.
Given that NuGet already tolower's package names to avoid this class of issues I think we should do the same in the Sdk attribute. CLI and VS will tolower the package name during layout generation and MSBuild will tolower whatever string is passed in by the user.
Note: NET was actually the right casing, so we changed the on-disk layout. However, this issue is still real as anyone typing an Sdk value may mix up caps and end up in the same broken state.
While merging in new templates from https://github.com/dotnet/sdk we took into CLI elements that looked like this:
Notice the capitalization of
NET
. The actual on-disk layout for these SDKs contain insteadNet
. This capitalization change did not cause issues on Windows as that is a case-insensitive file system but did cause issues on other platforms which are case-sensitive. The experience of tracking down this issue was frustrating because a capitalization problem in a file path is not one that immediately jumps out.Given that NuGet already
tolower
's package names to avoid this class of issues I think we should do the same in theSdk
attribute. CLI and VS willtolower
the package name during layout generation and MSBuild willtolower
whatever string is passed in by the user.@AndyGerlicher @srivatsn @dsplaisted @rainersigwald thoughts?
Note:
NET
was actually the right casing, so we changed the on-disk layout. However, this issue is still real as anyone typing anSdk
value may mix up caps and end up in the same broken state.