msbuild包指定版本?

问题描述 投票:0回答:1

这就是我现在用nuget pack做的事情:

nuget.exe pack myapp.csproj -IncludeReferencedProjects -Properties Configuration=Release;prerelease=INeedToSetThisFromTheCommandNotStaticConfigFile-123

msbuild包说没有

msbuild myapp.csproj /T:pack /p:Configuration=Release;prerelease="-INeedToSetThisFromTheCommandNotStaticConfigFile-123"

prerelease = -INeedToSetThisFromTheCommandNotStaticConfigFile-123:术语'prerelease = -INeedToSetThisFromTheCommandNotStaticConfigFile-123'不被识别为cmdlet,函数,脚本文件或可操作程序的名称。检查名称的拼写,或者如果包含路径,请验证路径是否正确,然后重试。

windows msbuild nuget
1个回答
0
投票

.csproj文件中,将标记Version设置为$(TheVersion),并从命令行设置此参数。

Configuration=Release;TheVersion=123

© www.soinside.com 2019 - 2024. All rights reserved.