任何现有的纯 PHP“make”工具?
让我详细说明这个问题...
我有一个自定义 CMS(基于 codeigniter FTW 构建),其中包含许多不同类型的模块。
每次我们有一个新项目出现时,它都是一些现有模块的变化和合并。
有时,一个项目的要求无法满足现有模块的要求,在这种情况下,我会编写一个新模块...
所有模块都在文件夹中分离出来,并且代码是使用 GIT 进行 VC 编辑的。每个模块都有自己的模型、视图、控制器、SQL 和 Javascript 文件。所有依赖项也被很好地分离和文件夹化...
我的下一步是创建某种安装程序脚本,它将引导我逐步完成“脚手架”过程,允许我从现有模块中进行选择。一个美化的“makefile”如果你可以的话......
而不是我自己的,有人知道任何这样的事情吗?
我知道 Apache ANT (java),我需要的是纯 PHP 中的依赖非常低或没有依赖的东西...
我想要像运行 git pull 然后运行 php 这样简单的东西make.php
谢谢。
Let me elaborate on the question...
I have a custom CMS (built on codeigniter FTW) that includes many different types of modules.
Every time we have a new project come through the door, it is a variation and amalgamation of a few of the existing modules.
Sometimes a project comes through with requirements that are not satisfied by the existing modules, in that case I will write a new module...
All the modules are separated out in folders and the code is VC-ed using GIT. Every module has it's own Model, View, Controller, SQL and Javascript files. All the dependencies are also separated and folder-ed nicely...
The next step for me is to create some sort of installer script that will take me through the "scaffolding" process step by step, allowing me to choose from the existing modules. A glorified "makefile" if you may...
Rather than rolling my own, does anyone know of any such thing out in the wild.
I know of Apache ANT (java), what I need is something in pure PHP with very low or no dependencies...
I would like something as simple as running a git pull
and then php make.php
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我所知道的 PHP 领域的“类似蚂蚁”的替代方案是 phing 它是用 PHP 编写的,它将允许您执行打包、部署和测试 Web 应用程序的多项任务。如果您想立即开始工作,文档是一个很好的起点。
如果需要的话,还可以扩展它来定义新任务(文档中提供了示例和解释)
通读 doco,似乎可以在没有 PEAR 的情况下安装 Phing,如文档所示 此处 您必须在要使用 Phing 的每台计算机上正确设置环境。但我无法确认此方法,因为我在所有安装中都使用 PEAR。
The "Ant-like" alternative I am aware of in PHP land is phing it is written in PHP and it will allow you to perform several tasks for packaging, deploying and testing your web applications. The documentation is a great starting point if you want to hit the ground running.
It is can also be extended to define new tasks if needed (examples and explanations are provided in the documentation)
Reading through the doco it appears to be possible to install Phing without PEAR as documented here you would have to correctly setup the environment on each machine you wish to use Phing on. I can not confirm this method though as I use PEAR for all my installs.