Quote from: redman at Sep 02, 2008, 04:22 AM
OG, what’s your reasoning for not wanting to use Phing? While it is another dependency, it allows svn tasks to be run and has a dbdeploy task. I haven’t started to use dbdeploy, but it looks like it could be useful for managing changes to the db schema.
Don’t want that kind of dependency in a critical piece of the core, which I consider the Transport Packaging system. That said, it makes perfect sense in your custom environment. We use Ant directly to build the various distributions of MODx Revolution and will be doing to same with xPDO, so I have no aversion to the tools really, just want the Transport Packaging to work in systems where Phing/Ant is not a possibility. This spells Core Extension to me.
Also, note that the Transport Packaging does not use any SQL, but instead deals with database portable object serializations. This will be important for sharing packages across database platforms when we release MODx Revolution for PostgreSQL, SQLite, or other engines.
Quote from: redman at Sep 02, 2008, 04:22 AM
development build:
* copies custom config files to the right place. The custom config files contain the db details. Different dbs (dev/staging/production) have different credentials for security, so the appropriate config file needs copying to the right place.
* purges the dev db
* imports the latest db snapshot
* imports snippets and chunks managed by svn into the db
* clears the modx site cache.
staging - this is run locally by devs after merging their changes into the branch, and prior to committing to the repo. I also intend for it to be run on the staging machine via CruiseControl following a trunk commit.
* purges the directory used for staging
* checks out each modx project that has been defined, builds each one (similar to the dev build process), removes .svn directories, and moves the files to the staging web root directory
* if it is running on the staging box, it will create documentation
* runs unit tests using phpunit (this part doesn’t work yet).
so, there’s quite a bit to do and phing integrates with all of the required tools.
Perhaps this is getting a bit custom, but could definitely be crafted as a core extension (with Phing) to do these specific things, but the specific steps would need to be definable (again, maybe allowing custom Phing scripts to be executed would be the way). With Transport Packages, you could do many of the same things, plus have the power of smart objects being moved around and the MODx core could be scripted against, as well.
Ultimately, with Phing, I’d like to see the liberated MODx API be integrated using it’s own custom Tasks; then Phing itself could be used within MODx or outside of it to script these actions with the same intelligent data handling, even between servers.