Show contentFiles from nuget packages in legacy project system
nkolev92 opened this issue · 7 comments
In the new project system, the static contentFiles from Nuget packages are linked and shown in the solution explorer.
The old project system should do the same.
Note that CommandStuff.cs is the only element from the package above the needs shown.
It's also marked as a link.
The example illustrates the difference in 15.7 P3.
ClassLibrary1 is legacy, ClassLibrary39 is SDK csproj.
Additionally it's important that these files are read-only.
Related issue to make them read-only in new project system - #2141
As more and more people are moving their projects as part of the effort in NuGet/Home#5877, this becomes more and more important.
Why does globalpackagesfolder show up here? My understanding was the contents of the contentfiles folder show up in the solution explorer.
@anangaur
That's just my test setup :)
When I test things with packages I build locally, I set the global packages folder to a directory inside the project, to avoid polluting my actual global packages folder.
And new project system just imports/shows everything under the project folder.
I guessed so but this makes the screenshot confusing. Can you clarify the following in the description?
- the content file in this case
- the layout of the this file in the package.
One thing missing from how the new project system handles contentFiles is that it doesn't make them read-only, so if you edit them, you're editing the file from the NuGet package cache folder.
When adding contentFiles support to the old project system, would it be possible to make them read-only from the initial implementation?
Tom's triage notes: I recommend we close this.