您可以在 Visual Studio 2008 中拥有或模仿解决方案级别的构建前和构建后事件吗?

发布于 2024-11-14 19:10:21 字数 367 浏览 3 评论 0原文

我想知道是否有能力在解决方案级别(而不仅仅是在 Visual Studio 2008 中的项目级别)拥有或至少模拟构建前和构建后事件?

因此,如果可能的话,我希望此功能与它们在项目级别的工作方式类似,但我只希望它们在构建任何项目之前和构建任何项目之后运行。例如,如果可能的话,可以使用宏的命令行样式,但是可以很高兴能够指定一个或多个要按顺序运行的 CMD 文件。

在最糟糕的情况下,我可以创建 MSBuild .proj 文件以及如何让它被 sln 文件识别以在任何类型的交易之前运行,并在所有类型的交易之后运行另一个文件吗?

只要是在核心 VS2008 和 MSBuild 功能范围内,任何其他获得类似行为的建议都会受到欢迎。我不能要求使用任何加载项或扩展来完成此任务。

I would like to know if there is anyway to get the ability to have or at least mimic Pre and Post build events at the Solution level not just at the project level within Visual Studio 2008?

Therefor if possible I would like this functionality to be similar to how they work at the project level, except I only want them to run before building any projects and after building any projects. For example to be a command-line style with Macro's if possible, however could be happy with being able to specify one or more CMD files to be run in order.

At worse case, can I create MSBuild .proj file and some how get it to be recognized by the sln file to run before anything and another after everything type of deal?

Any other suggestions to get similar behavior are welcomed as long as they are within the core VS2008 and MSBuild functionality. I cannot require the use of any add-ins or extensions to accomplish this.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

慕烟庭风 2024-11-21 19:10:21

对于后期构建,您可以在 lib/app 项目的后期构建中执行此操作吗?

对于预构建,您应该能够创建一个项目,然后设置项目依赖项,以便一切都依赖于它。如果您不想使用 lib/app 项目的后期构建,则可以对后期构建执行相反的操作。

编辑:当然,正如所指出的,这实际上不适用于后期构建。杜尔。

For the post-build, can you just do it in your lib/app project's post-build?

For the pre-build, you should be able to create a project and then set your Project dependencies such that everything depends on it. You can do the reverse for post-build if you don't want to use your lib/app's project's post-build.

EDIT: Of course, as pointed out, this won't actually work with the post-build. Durr.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文