NuGet silently overwrites nested file

Topics: General
May 26, 2014 at 3:54 PM

I have a nuget package containing two content files:
<file src="..\Playground\Host\Default.aspx.pp" target="content" />
<file src="..\Playground\Host\Default.aspx.cs.pp" target="content" />
(The .pp extension lets nuget replace some variables inside the file upon adding them to the project. See nuget docs for more info.)

When these two files get added to my project, VisualStudio autmatically declares the Default.aspx.cs file dependent upon the Default.aspx file and creates an additional designer file:

Project structure

Now if the user modifies both the .aspx and the .aspx.cs files and then updates the package to a newer version, nuget will ask for confirmation before overwriting this files. This works as expected.

If the user changes the .aspx.cs file without modifying the *.aspx file, nuget will overwrite the aspx.cs file without further warning - let alone asking for confirmation.

Is there any way to have nuget ask for confirmation before overwriting a nested file?
Nov 21, 2014 at 9:30 AM
Same problem here.
Have You found a solution?
Nov 21, 2014 at 4:21 PM