Undocumented replacement token $configuration$

Topics: General
Nov 27, 2012 at 3:30 PM

I have stumbled upon an undocumented replacement token for the <files /> section in a nuspec file. The way I am using it is:

<files>
    <file src="bin\$configuration$\$id$.pdb" target="lib\net40\"/>
</files>

I was wondering if anyone would be able to tell me how safe using this procedure is, and if it's a lack of documentation or a rogue feature.

Thank You.

Nov 27, 2012 at 7:34 PM

This is safe. Feel free to use it.

Nov 27, 2012 at 10:12 PM

Hello dotnetjunky,
Thank You for your fast reply. I had a little time to take a look at the source after work.
Am I correct with my assumption that all msbuild properties are exposed via the IPropertyProvider interface?
This is awesomely powerful, and I was wondering, if this is the case, would you be happy for me to contribute to the documentation?

Thank You.

P.S. Posting from private account now.

Coordinator
Dec 8, 2012 at 6:54 AM

Wow, I knew we supported that syntax for element values in the metadata section, but I didn't realize it worked within a file src. 

Please do update the docs here: https://github.com/NuGet/NuGetDocs/blob/master/site/Docs/Reference/Nuspec-Reference.markdown

Phil