如何自动构建 Visual FoxPro 项目?

发布于 2024-09-02 17:08:32 字数 345 浏览 7 评论 0原文

我有兴趣弄清楚如何从 Visual FoxPro 自动化构建,类似于我们如何使用 MSBuild

似乎可以将命令行参数传递给 VFP。 exe,其中可能包括指定一些运行的初始启动程序的能力,但目前尚不清楚从非交互式帐户(例如 Windows 上的网络服务,这很可能是自动构建的地方)启动 IDE 的效果如何跑步。

之前是否有人尝试过此操作或读过有人尝试编写这样的 VFP 构建脚本?我将不胜感激任何可能引导我找到解决方案的指示。

I'm interested in figuring out how to automate a build from Visual FoxPro similar to how we can build .NET projects from the command line using MSBuild.

It seems that it is possible to pass command line arguments to VFP.exe which may include the ability to specify some initial startup prg that runs however it is unclear how well starting up the IDE will work from non-interactive accounts such as the Network Service on Windows which is likely where an automated build would run.

Has anybody attempt this before or read about anybody attempting to script a VFP build like this? I would be grateful for any pointers that may lead me to a solution.

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

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

发布评论

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

评论(2

り繁华旳梦境 2024-09-09 17:08:32

一个简单的解决方案是创建一个构建应用程序的程序文件,并调用 VFP 来执行该程序。您还可以将任何构建前或构建后命令添加到该程序文件中。

创建一个 VFP 配置文本文件,名为 BUILD.FPW

SCREEN=OFF
COMMAND=DO C:\Project\BUILD.PRG

然后创建 C:\Project\BUILD.PRG

Modify Project C:\Project\MyProject Nowait
_vfp.Projects.Item(1).Build("C:\Project\myapp.exe", 3, .f., .f.)
If file("C:\Project\myapp.err")
    * Do something for build errors
Else
    * No errors
Endif
Quit

最后,为了构建它,

C:\Program Files\Microsoft Visual FoxPro 9\vfp9.exe -CBUILD.FPW

VFP 将以非交互方式构建它。它将把构建错误记录到 myapp.err 中。如果构建成功,则不会创建错误文件。

A simple solution is to create a program file that builds the application, and call VFP to execute that program. You can also add any pre or post build commands to that program file.

Create a VFP configuration text file, called BUILD.FPW

SCREEN=OFF
COMMAND=DO C:\Project\BUILD.PRG

Then create C:\Project\BUILD.PRG

Modify Project C:\Project\MyProject Nowait
_vfp.Projects.Item(1).Build("C:\Project\myapp.exe", 3, .f., .f.)
If file("C:\Project\myapp.err")
    * Do something for build errors
Else
    * No errors
Endif
Quit

Finally, to build it

C:\Program Files\Microsoft Visual FoxPro 9\vfp9.exe -CBUILD.FPW

VFP will build it non-interactively. It will log build errors to myapp.err. If it builds successfully, no error file is created.

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