nuspec

How to to produce both release and pre-release packages from one nuspec in VSTS?

狂风中的少年 提交于 2019-12-22 18:02:10
问题 Currently my build produces both packages having a newer version every time: Release: Automatic package versioning = Use the build number Pre-release: Additional build properties = Version=$(user.BuildFullVersion)-beta And the only one nuspec has a placeholder to version: <version>$version$</version> I want to increment version manually, that it - repetitive build would produce same version until I increment it manually. How can I achieve that still having single nuspec? Can I adjust package

Deployment of contentFiles in NuGet 3.3

淺唱寂寞╮ 提交于 2019-12-22 11:35:35
问题 NuGet 3.3 release few days ago supports contentFiles . I've created a package using nuget.exe according to Nuspec reference, but when I installed it to a project (based on ASP.NET 5 RC1), no files are added. Is there some complete example how it should work, please? Are there already some packages on nuget.org with contentFiles ? Thanks. 回答1: Apparently ASP.NET doesn't support contentFiles yet. https://github.com/aspnet/Home/issues/651 来源: https://stackoverflow.com/questions/34045140

How to exclude a subdirectory and contents from a nuget package

天涯浪子 提交于 2019-12-22 10:34:46
问题 So I've a website that I'm trying to package for Octopus Deploy. I've the following folder structure: Web | Views | WantThis Dontwantthis WantThis1 WantThis2 ... (lots more) Scripts I'm trying to exclude the "Dontwantthisfolder" So my nuspec looks like this: ... <file src="..\Web\Views\**\*.*" exclude="**\Dontwantthis\**" target="web\Views" /> ... It's not working though, I still get the "Dontwantthis" folder. Anyone know how I can achieve this? 回答1: You're quite close. Try this: <files>

How to debug using Nuget source code

北城余情 提交于 2019-12-22 00:35:06
问题 As a temporary solution (until we get an internal Symbol server setup), I am trying to build Nuget packages that include all source code for the DLL so that our users can debug its code. I have build the following Nuspec file <?xml version="1.0" encoding="utf-8"?> <package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd"> <metadata> <id>My Assembly</id> <version>1.0.0</version> <title>My Assembly</title> <authors>Me</authors> <owners>Me</owners> <requireLicenseAcceptance

Msbuild v15 can't resolve the variables of metadata of nuspec file

[亡魂溺海] 提交于 2019-12-19 07:53:48
问题 I know Since the release of msbuild 15 (vs 2017) that NuGet is now fully integrated into MSBuild. I have a nuspec file with defining variables of package properties like: <metadata> <id>$id$</id> <version>$version$</version> <authors>$authors$</authors> ... </metadata> The nuspec file is located in the same folder of the project. When using nuget tool to create the package , it works fine. nuget pack When using msbuild v15, it raise an exception. run the command: msbuild -version Microsoft (R

Msbuild v15 can't resolve the variables of metadata of nuspec file

落花浮王杯 提交于 2019-12-19 07:53:20
问题 I know Since the release of msbuild 15 (vs 2017) that NuGet is now fully integrated into MSBuild. I have a nuspec file with defining variables of package properties like: <metadata> <id>$id$</id> <version>$version$</version> <authors>$authors$</authors> ... </metadata> The nuspec file is located in the same folder of the project. When using nuget tool to create the package , it works fine. nuget pack When using msbuild v15, it raise an exception. run the command: msbuild -version Microsoft (R

How to include directories recursively in NuSpec file

和自甴很熟 提交于 2019-12-18 12:17:54
问题 I have a folder structure like this in my project... Project/Folder1/Folder2 -File1 -File2 -File3 Project/Folder1/Folder3 -File4 -File5 -File6 Project/Folder1/Folder4 -File7 -File8 In a NuSpec definition file, how can I tell it to include everything under Folder1 (folders and files recursively)? Can I just do this or do I need a double ** or what? <file src="Project\Folder1\*.*" target="Project/Folder1" /> 回答1: You can use the wildcard ** which is documented on the NuGet web site. From the

nuget spec dependencies, get latest version?

做~自己de王妃 提交于 2019-12-17 10:58:08
问题 In the nuspec versioning docs I see 1.0 = 1.0 ≤ x (,1.0] = x ≤ 1.0 (,1.0) = x < 1.0 [1.0] = x == 1.0 (1.0) = invalid (1.0,) = 1.0 < x (1.0,2.0) = 1.0 < x < 2.0 [1.0,2.0] = 1.0 ≤ x ≤ 2.0 empty = latest version. I have a packages.config that looks like this <packages> <package id="psake" version="4.2.0.1" /> </packages> and I would like to change the version to "latest". I've tried both <packages> <package id="psake" version="" /> </packages> and <packages> <package id="psake" /> </packages>

How install Nuget package when building project in Visual Studio

自作多情 提交于 2019-12-11 17:13:59
问题 My project uses an executable called wkhtmltopdf that converts an HTML into a pdf. I've created a NuGet package that simply output the exe in the root of the project so that it can be referenced and used by my application. If I install the nuget package everything works fine, meaning that the executable is added into my application and I can work with it. The problem is that I don't want to commit the executable but I want that if another dev pull down my project and build it, the executable

App.config XML transform from NuGet Package

我的未来我决定 提交于 2019-12-11 10:52:02
问题 I am attempting to follow these instructions to perform a simple XML transform on a target App.config file via a custom NuGet package. The app.config.transform file contains the following content: <configuration> <appSetttings> <add key="foo" value="bar" /> </appSetttings> </configuration> The .nuspec file contains the following content: <?xml version="1.0"?> <package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"> <metadata> <id>Foo.Bar</id> <version>1.0.0</version> <title