资源说明:A skeleton for new symfony 1.x projects
# symfony1-skeleton A skeleton for new symfony1 projects. ### Features * [Apache Ant](http://ant.apache.org/) build file * defaults for [HudsonCI](http://hudson-ci.org) integration * targets for symfony operation * **release** target for Hudson's [Release Plugin](http://wiki.hudson-ci.org/display/HUDSON/Release+Plugin) * script for displaying project information in dev/staging environments * special symfony library include file for working in different environments ## Creating a New Project The following are my recommended instructions for creating a new project based on this skeleton. ### Step 1 - Clone this repository Clone symfony1-skeleton repo locally (do not fork for new projects) git clone git@github.com:kbond/symfony1-skeleton.git [project-name] ### Step 2 - Setup your project Delete .git folder rm -rf .git Clear out ``README.md`` Open ``config/properties.ini`` - set your project information Open ``build.xml`` and update ``dispatch(); require_once 'info.php'; ``` ## build.xml This skeleton comes with an Apache Ant ``build.xml`` file that includes some useful *targets*. Make sure you have Apache Ant installed or use an IDE like [Netbeans](http://www.netbeans.org). Additional comments are in the ``build.xml`` file. * ``symfony.dir``: creates directories in your project required by symfony * ``symfony.lib.embed``: checks out the symfony library to ``lib/vendor/symfony`` * ``symfony.lib.shared``: adds a shared symfony library to ``config/include.php`` * ``symfony.clearcache``: calls ``symfony cc`` * ``symfony.permissions``: calls ``symfony project:permissions`` * ``symfony.plugins``: installation of 3rd party plugins * ``project.config``: any configuration to be run on CI server (ie. load fixtures) * ``project.test``: runs your project's test suite There are some additional targets that are intended for you CI server. ## Hudson CI setup The included Apache Ant build script integrates nicely into Hudson. There are predefined build and release targets. **build**: cleans up the workspace, runs your test suite and outputs the current build number to ``./BUILD_NUMBER``. **release**: Utilizes the Hudson *Release Plugin* to git tag a release. #### Requirements: * [Hudson CI](http://hudson-ci.org/) * [Git Plugin](http://wiki.hudson-ci.org/display/HUDSON/Git+Plugin) * [Release Plugin](http://wiki.hudson-ci.org/display/HUDSON/Release+Plugin) (optional) ### Instructions 1. Add a new Job and configure 2. Source Code Management -> Git * Set *URL of repository* * *Branch Specifier*: ``master`` * Click *Advanced...* * *Checkout/merge to local branch*: ``master`` 3. Add Build Step -> Invoke Ant * *Targets*: ``build`` 4. (optional) Build Environment -> Configure release build 5. (optional) Post-Build Actions -> Git Publisher * *Push Only If Build Succeeds* * *Add branch* * *Branch to push*: ``latest-stable`` * *Target remote name*: ``origin`` 6. Invoke initial build! *Step 4 requires Release Plugin* *Step 5 creates a *latest-stable* branch in your git repository*
本源码包内暂不包含可直接显示的源代码文件,请下载源码包。