Table of contents:
Also known as svn or SVN.
Wikipedia on Subversion!
Use of Subversion for your eZ Publish projects is now deprecated.
The business and community projects for eZ Publish are all (slowly) migrating to using Git for version control.
We strongly recommend you replacing your Subversion usage with Git today.
Using Subversion to manage your eZ publish site development.
Reasons to use subversion to store the site specific customization
It can often be time consuming to perform a manual commit to a site repository checkout with changes made to it by eZ publish. Especially adding or removing 1000+ files from the checkout. Here are some example commands which can be used to automate this process. After using these commands you may perform a hand commit or a mass (general/all files) commit.
Add new files in var/storage to svn checkout
# cd /web/pro/example.com/; find /home/web/pro/example.com/var/plain/storage/original/application -print0 | xargs -0 svn status | grep '? ' | tr '? ' '\n' | xargs svn add
Remove files from svn which have been removed from var/storage by eZ publish
# cd /web/pro/example.com/; find /web/pro/example.com/var/plain/storage/ -print0 | xargs -0 svn status | grep '! ' | tr '! ' '\n' | xargs svn remove
Log svn status command results to log file
# cd /web/pro/example.com/; svn status | tee ../example.com.status.2006.11.17.001.log
Unpack stock eZ publish and prepare build and create links
# cat /web/ini/bin/int.stock.svn.links.sh #!/bin/bash wget https://ez.no/content/download/152158/995731/file/ezpublish-3.8.6-gpl.tar.gz tar -zxf ezpublish-3.8.6-gpl.tar.gz ln -s ezpublish-3.8.6-gpl doc cd doc # move stock folders to invisible mv bin .bin; mv var .var; mv design .design; mv extension .extension; mv settings/override settings/.override; mv settings/siteaccess settings/.siteaccess; # create links ln -s ../example.com/bin bin; ln -s ../example.com/var var; ln -s ../example.com/design design; ln -s ../example.com/extension extension; ln -s ../example.com/settings/override settings/override; ln -s ../example.com/settings/siteaccess settings/siteaccess;
Example eZ publish stock layout with symlinks to site repository checkout.
# ls -l .ezpublish.3.8.6.stock access.php bin -> ../example.com/bin .bin.stock clr -> bin/shell/clearcache.sh cronjobs design -> ../example.com/design .design.stock doc extension -> ../example.com/extension .extension.stock ezpm.php ezpublish.cron index_image_mysql.php index_image_pgsql.php index_image.php index.php kernel kickstart.ini-dist lib LICENSE packages pre_check.php README.txt runcronjobs.php settings share soap.php support update var -> ../example.com/var .var.stock webdav.php # ls -la settings override -> ../../example.com/settings/override .override.stock siteaccess -> ../../example.com/settings/siteaccess .siteacces.stock
Example site repository layout
# ls -l bin design extension favicon.ico -> favicons/example.white.star.ico favicons robots.txt settings tmp var
Note: This method has a few negative side affects long term maintenance. First storing the extension directory as a whole provides for stronger extension source code management.
Yet for general purpose usage this notion of storing the extension dir should be removed and replaced instead with an abstraction. Instead of storing extensions per site repository, store your extensions in a separate repository, install ezsvn and use it to install your extensions needed via external repository.
Second, the design directory should really only contain the non-stock site design directories. These would be symlinked into your existing stock design directory.
Third, the settings directory should really only contain the non-stock override and siteaccess directories. These would be symlinked into your existing stock design directory.
This is a Stub article. Help the eZ Publish community by expanding it!
Article provided by eZpedia
All text is available under the terms of the GNU Free Documentation License
Powered by eZ Publish Community Project 4.2011
Hosted by Swiss eZ Publish partner YMC