Can I create a nuget package without a project file

不想你离开。 提交于 2019-12-11 03:54:07

问题


We are trying to integrate Octopus-Deploy with our existing build process. Octopus-Deploy expects nuget packages to deploy. Now, for a variety of reasons, we change various file configurations after the build against the compiled files, so if we used the octopack tool, the packaging happens too early in our build process for us.

We will end up with a folder of e.g. mywebsite_QA and mywebsite_UAT, each containing the correct config files, etc, and it is thesefolders that we wish to deploy.

I would like to take these already built files, (mostly web applications) and turn them into nuget packages.

I am a bit of a noob with nuget, and I cannot see an easy way to do this, because it seems to require a project file or assembly.

Is there some way to take a web site directory structure and turn it into a nuget package?


回答1:


Yes you can, see the Nuget pack documentation http://docs.nuget.org/docs/reference/command-line-reference#Pack_Command

Just run nuget.exe with the right options during your build process.

If you are using TeamCity, you can use it's Nuget package step.



来源:https://stackoverflow.com/questions/22977258/can-i-create-a-nuget-package-without-a-project-file

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!