寻找用于自动构建和构建的脚本语言部署

发布于 2024-09-15 00:28:41 字数 794 浏览 2 评论 0原文

我将开始为我们的软件团队编写一个自动构建/部署脚本,但我不确定要使用哪种脚本语言或工具。我总是渴望学习新的东西并提高我在当前软件市场上的价值,那么您建议使用什么语言? 过去,我使用 Windows 批处理文件,读取和编写脚本有点难看。

这里简单说一下我的需求和环境:

  • Development under Win XP using Visual Studio 2008 (C++)
  • 颠覆,
  • 寻找易学易用的解决方案使用 语言
  • PHP 和脚本 编程经验红宝石与C++

我希望脚本能够

  • 检查
  • clean &构建许多项目
  • 检查错误冲洗并重复 直到没有错误或超时
  • 运行单元测试并评估结果(文本解析)
  • 压缩一堆 dll/exe 并复制到 如果可能的话,服务器
  • 冲一杯咖啡

感谢您的任何建议。可能是一个社区维基,因为没有明确的答案,对此不确定...

编辑:

找到这些讨论,但它们有点旧,也许已经过时了:
如何自动化 Visual Studio 构建?
最佳 .NET 构建工具

I'll start to write a automated build/deploy script for our software team, and I'm not sure which scripting language or tool to use. I'm always eager to learn something new and improve my value on the current software market, so what language do you propose?
In the past, I used windows batch files, which are kind of ugly to read and script.

Here are few words as of my requirements and environment:

  • developing under Win XP using Visual
    Studio 2008 (C++)
  • subversion
  • looking for easy to learn & use
    scripting language
  • programming experience in PHP & Ruby & C++

I want the script to

  • checkout
  • clean & build many projects
  • check for errors rinse and repeat
    until no errors or timeout
  • run unittests and evaluate results (text parsing)
  • zip a bunch of dlls/exe and copy to
    server
  • brew a cup of coffee if possible

Thanks for any suggestions. Could be a community wiki since there's no definite answer, not sure about that...

EDIT:

Found those discussions, but they are a little older and perhaps outdated:
How do you automate a Visual Studio build?
Best .NET build tool

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

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

发布评论

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

评论(4

﹏半生如梦愿梦如真 2024-09-22 00:28:41

我建议设置一个 CI 服务器(Hudson?)并使用它来控制所有< /em> 部署到您的 QA 和生产服务器。这迫使您自动化部署的所有方面,并确保开发人员不会临时重新启动系统。

我进一步建议您考虑将构建输出发布到存储库管理器,例如 Nexus 、 Artifactory 或 Archiva 。通过这种方式,部署脚本可以检索先前构建的任何版本。使用存储库管理器将使您的 QA 团队能够在将版本部署到生产之前对其进行认证。

最后,考虑一种新兴的部署自动化工具。 chefpuppetControlTier 可用于进一步版本控制基础设施的配置。

I'd suggest setting up a CI server (Hudson?) and use this to control all deployments to both your QA and production servers. This forces you to automate all aspects of deployment and ensures that the are no ad-hoc restarts of the system by developers.

I'd further suggest that you consider publishing your build output to a repository manager like Nexus , Artifactory or Archiva. In that way deployment scripts could retrieve any version of a previous build. The use of a repository manager would enable your QA team to certify a release prior to it's deployment onto production.

Finally, consider one of the emerging deployment automation tools. Tools like chef, puppet, ControlTier can be used to further version control the configuration of your infrastructure.

以为你会在 2024-09-22 00:28:41

有人简短地提到,我喜欢 PERL 来完成这些事情。在我从事的一个绝对庞大的项目中,我们使用 Perl 脚本来运行整个构建过程。它甚至基于消息传递模板构建了类。这非常酷,而且这是一个可以启动的 Windows 项目。

CPAN 提供了巨大的资源。

华泰

It was briefly mentioned, I like PERL for these sorts of things. On an absolutely humongous project I worked on, we had perl scripts practically running the entire build process. It even built classes based upon messaging templates. It was pretty cool, and this was a Windows project to boot.

CPAN provides an enormous resource.

HTH

我要还你自由 2024-09-22 00:28:41

我推荐使用 python 来完成此类通用脚本编写任务;它是一种相对容易学习并且非常灵活的语言。

特别是,您可以使用 subprocess 模块来调用您需要的所有外部程序;它使得捕获它们的输出并控制它们变得非常简单。

I would recommend python for this sort of generic scripting task; it's a relatively easy language to learn and very flexible.

In particular, you would use the subprocess module to call all the external programs that you need; it makes capturing their output and controlling them very straightforward.

一片旧的回忆 2024-09-22 00:28:41

成功使用后,我目前正在将 Apache Ant 与 MPC (自制跨平台项目)结合使用尽管 XML 并不完全符合脚本语言的资格,但我以前的一份工作中的组合。但除了一杯咖啡之外,它可以做你清单上的所有事情。 MPC 是用 Perl 编写的,非常灵活,例如,它允许您为 VS 项目指定构建后和预构建操作。

编辑:我刚刚浏览该网站,偶然发现了这个 问题< /a>;查看有关的答案
FinalBuilder (我正在考虑尝试一下;不过你必须付费)

I'm currently using Apache Ant combined with MPC (home brewed cross platform project) after successfully using the combination at one of my previous jobs, though XML does not quite qualify as a scripting language. But except for the cup of coffee it can do everything on your list. MPC is written in Perl and it's pretty flexible e.g. it allows you to specify postbuild and prebuild actions for VS projects.

EDIT: I was just browsing the site and stumbled on this question; see the answer about
FinalBuilder (I'm considering giving it a try; you'd have to pay for it though)

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