是否可以将构建后任务/步骤添加到 Visual Studio 网站项目?
我在 Visual Studio 中有一个 ASP.NET 2.0 网站项目,我已经研究了一段时间了。随着时间的推移,该项目逐渐成长,最终,每次我想发布该项目时,我都必须在最后运行相当多的步骤。
因此,我编写了一个可以运行的脚本,它为我执行所有清理步骤,并且非常可靠。
现在,我非常不满意地发现 Visual Studio 2005 没有提供任何方法来执行网站项目的后期构建任务。我有办法做到这一点吗?
I've got this ASP.NET 2.0 website project in Visual Studio that I've been working on for a while now. Over time the project grew little by little and in the end I ended up with quite a few steps that I had to run at the end, every time I wanted to publish the project.
So, I wrote a script that I can run which executes all the clean-up steps for me and which is pretty reliable.
Now, I was very dissatisfied to find that Visual Studio 2005 doesn't provide any means to execute post build tasks with website projects. Is there a way I can do that?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
一项建议是转换为 Web 应用程序项目。
One suggestion is to convert to a Web Application Project.
另一种解决方案是为您的网站创建一个 Web 部署项目,并在其项目文件中添加 MSBUILD 任务。
The other solution would be to create a web deployment project for your website and add a MSBUILD task in its project file.