0byt3m1n1
Path:
/
data
/
applications
/
aps.bak
/
coppermine
/
1.5.12-0
/
standard
/
htdocs
/
docs
/
fr
/
[
Home
]
File: dev_subversion.htm
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en" dir="ltr"> <head> <title>Subversion - Coppermine Photo Gallery - Documentation & Manual</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <meta name="language" content="en" /> <meta name="copyright" content="Coppermine dev team" /> <meta name="description" content="Subversion: This part of the documentation is not meant for end users of Coppermine, but only for developers. There is no support for this section, it comes as-is." /> <meta http-equiv="Content-Style-Type" content="text/css" /> <meta name="MSSmartTagsPreventParsing" content="true" /> <meta http-equiv="imagetoolbar" content="no" /> <!-- SVN version info: Coppermine version: 1.5.12 $HeadURL: https://coppermine.svn.sourceforge.net/svnroot/coppermine/trunk/cpg1.5.x/docs/fr/dev_subversion.htm $ $Revision: 8154 $ $Date: 2011-01-02 20:44:22 +0100 (So, 02 Jan 2011) $ --> <link rel="stylesheet" type="text/css" href="../style/style.css" media="all" /> <link rel="stylesheet" type="text/css" href="../style/screen.css" media="screen" /> <link rel="stylesheet" type="text/css" href="../style/print.css" media="print" /> <link rel="shortcut icon" href="../favicon.ico" /> <script src="../js/jquery.js" type="text/javascript"></script> <script src="../js/jquery.treeview.js" type="text/javascript"></script> <script src="script.js" type="text/javascript"></script> </head> <body> <h1 id="docheader">Coppermine Photo Gallery v1.5.x: Documentation and Manual</h1> <div id="toc"> <a href="toc.htm">Table of Contents</a> </div> <div id="doc_en_only">No translation available</div> <a name="subversion"></a><h1>Subversion<a href="#subversion" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h1> <p>As Coppermine is a community effort, with various developers working on it simultaneously, there is the need to have a tool that allows the developers to organize their submissions.</p> <p>Subversion (SVN) is a version control system initiated in 1999 by <a href="http://www.collab.net/" rel="external" class="external">CollabNet Inc</a> that is used to maintain current and historical versions of files such as source code, web pages, and documentation.</p> <a name="dev_subversion_target_audience"></a><h2>Target audience<a href="#dev_subversion_target_audience" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <p>This part of the documentation is not meant for end users of Coppermine, meaning: you don't have to read this nor do you (as end user) have to check out the Subversion repository. However: if you know your way around in Coppermine and would like to see the bleeding edge of Coppermine technology, you're welcome to read this page and check out Coppermine using Subversion access. Primary target audience for this page are coppermine developers though.</p> <a name="dev_subversion_caveat"></a><h2>Caveats<a href="#dev_subversion_caveat" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <p>As suggested in the <a href="testing.htm">testing docs</a>, you (as an end user) are welcome to check out the development versions of Coppermine. However, you have to understand that both subversion access as well as development versions go completely, utterly unsupported.</p> <a name="dev_subversion_definition"></a><h2>What is subversion?<a href="#dev_subversion_definition" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <p>Subversion is a revision control system which allows computer software to be developed in an incremental and controlled fashion by a distributed group of programmers. Also commonly referred to as svn or SVN, Subversion is designed specifically to be a modern replacement for <abbr title="Concurrent Versions System">CVS</abbr> [<a href="http://en.wikipedia.org/wiki/Concurrent_Versions_System" rel="external" class="external">definition</a>]. Subversion was created by <a href="http://www.collab.net/" rel="external" class="external">CollabNet</a>, who still maintain the project.</p> <p>SVN provides the means to store not only the current version of a piece of source code, but a record of all changes (and who made those changes) that have occurred to that source code. Use of SVN is particularly common on projects with multiple developers, since SVN ensures changes made by one developer are not accidentally removed when another developer posts their changes to the source tree.</p> <a name="dev_subversion_hosting"></a><h2>Where is the subversion repository hosted?<a href="#dev_subversion_hosting" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <p>Setting up and maintaining a subversion server is something that you can't accomplish on a "regular" webserver (on shared webhosting). That's why the Coppermine group has decided to host the subversion repository at <a href="http://sourceforge.net/" rel="external" class="external">sourceforge.net</a>, who provide hosting and services for many open source projects. Originally, the Coppermine project started using Sourceforge's CVS services and later moved to SVN.</p> <a name="dev_subversion_software"></a><h2>Recommended software<a href="#dev_subversion_software" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <ul> <li>Free SVN client for Windows: <a href="http://tortoisesvn.net/" rel="external" class="external">TortoiseSVN</a></li> <li>Official SVN client for Linux and BSD: <a href="http://subversion.tigris.org/" rel="external" class="external">subversion.tigris.org</a></li> <li>Recommended GUI client for Linux: <a href="http://rapidsvn.tigris.org/" rel="external" class="external">RapidSVN</a> (available as a pre-made package for many Linux distributions)</li> </ul> <a name="dev_subversion_websvn"></a><h2>Alternative access using Web SVN<a href="#dev_subversion_websvn" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> For those who don't want to download and install a full SVN client software there is also a usefull tool available called "Web SVN", where the subversion server provides a web-driven interface to browse the structure of the SVN repository. This interface gives you the opportunity to download a tarball archive of the repository, and you can download or view individual files as well. You can not commit your changes with it, so it's no use for developers. You're encouraged to use web SVN first and if you feel familiar with that go for the "real" svn client. <a name="dev_subversion_repository_structure"></a><h2>Repository structure<a href="#dev_subversion_repository_structure" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <div class="indent"> <p>The coppermine SVN root resides in <tt class="code">https://coppermine.svn.sourceforge.net/svnroot/coppermine</tt><br /> Within this section you will find several folders: the "trunk" folder contains the mainstream folders of the existing coppermine versions. In the "branches" folder, there are copies of the mainstream versions that are being created as a fork of the mainstream versions, used by particular developers or groups that need control over the structure for a longer period (e.g. during the "summer of code"-stage) to add in-depth changes.</p> <div class="cpg_message_success" id="toc_main"> <a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/">Coppermine Subversion repository</a> <ul class="treeview"> <li> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/">branches</a></span> <span class="small">Add-ons, Plugins, Themes and all sorts of additional stuff</span> <ul> <li> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.4.x/">cpg1.4.x</a></span> <span class="small">Contributions for cpg1.4.x</span> <ul> <li> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.4.x/plugins/">plugins</a></span> <span class="small">Plugins for cpg1.4.x</span> </li> </ul> </li> <li> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/">cpg1.5.x</a></span> <span class="small">Contributions for cpg1.5.x</span> <ul> <li class="strikethrough"> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/JCpg/">JCpg</a></span> <span class="small">Student project during <abbr title="Google Summer Of Code">GSoC</abbr>2007 [<a href="http://code.google.com/soc" rel="external" class="external">→ project page</a>] that was meant as an alternative, Java-driven uploader - ignore!</span> </li> <li class="strikethrough"> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/gsoc2007/">gsoc2007</a></span> <span class="small">Fork created for the GSoC2007 - ignore!</span> </li> <li class="strikethrough"> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/gsoc2008/">gsoc2008</a></span> <span class="small">Fork created for the GSoC2008 - ignore!</span> </li> <li> <span class="floatleft bold"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/icons/">icons</a></span> <span class="small">Graphical resources for use in a theme of your own</span> </li> <li> <span class="floatleft bold"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/">plugins</a></span> <span class="small">Plugins for cpg1.5.x</span> </li> <li> <span class="floatleft bold"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/themes/">themes</a></span> <span class="small">Themes for cpg1.5.x</span> </li> </ul> </li> </ul> </li> <li class="strikethrough"> <span class="floatleft">tags</span> <span class="small">Currently unused - ignore!</span> </li> <li> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/">trunk</a></span> <span class="small">This is where the coppermine packages reside in, i.e. the different coppermine versions</span> <ul> <li> <span class="floatleft"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/cpg1.4.x/">cpg1.4.x</a></span> <span class="small">The cpg1.4.x- series code</span> </li> <li> <span class="floatleft bold"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/cpg1.5.x/">cpg1.5.x</a></span> <span class="small">The cpg1.5.x-series code</span> </li> <li class="strikethrough"> <span class="floatleft">cpgNGDevel</span> <span class="small">Development has been abandoned - ignore!</span> </li> <li class="strikethrough"> <span class="floatleft">cpgdbal</span> <span class="small">Early fork of cpg1.5.x where database abstration was tested - ignore!</span> </li> </ul> </li> </ul> </div> <div class="indent"> <a name="dev_subversion_repository_structure_trunk"></a><h3>Coppermine core files<a href="#dev_subversion_repository_structure_trunk" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> The most recent version of the Coppermine package for cpg1.5.x resides in the repository structure under <tt class="code">https://coppermine.svn.sourceforge.net/svnroot/coppermine/trunk/cpg1.5.x</tt>, i.e. it is available via <a href="#dev_subversion_websvn">web SVN</a> over <a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/cpg1.5.x/">http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/cpg1.5.x/</a>. <a name="dev_subversion_repository_structure_plugins"></a><h3>Plugins<a href="#dev_subversion_repository_structure_plugins" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>The most recent version of the <a href="plugins.htm#plugin">plugins</a> for cpg1.5.x that are being maintained in the subversion repository (not all plugins are under version management) resides in the repository structure under <tt class="code">https://coppermine.svn.sourceforge.net/svnroot/coppermine/branches/cpg1.5.x/plugins</tt>, i.e. it is available via <a href="#dev_subversion_websvn">web SVN</a> over <a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/">http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/</a>.</p> <p>When <a href="#dev_subversion_download_tarball">downloading a tarball archive</a> of a particular plugin, please understand that the difference between a zip download of a plugin from the download repository and a tarball download from the subversion repository mainly lies in the structure: in the zip file, there should be a folder that you need to upload to the plugins folders of your gallery. The tarball on the other hand doesn't reside in a folder, so you have to create that folder within the plugins folder first. You can not name it as you want to: instead, you need to preserve the name that the folder has got in the subversion repository.</p> <p class="cpg_example">If you are downloading a tarball from the folder <tt class="code">https://coppermine.svn.sourceforge.net/svnroot/coppermine/branches/cpg1.5.x/plugins/coffee_maker</tt>, you need to manually create a folder (using your FTP app) named <tt class="code">coffee_maker</tt> in <tt class="code">http://yoursite.tld/your_coppermine_folder/plugins/</tt>. Then, after having created <tt class="code">http://yoursite.tld/your_coppermine_folder/plugins/coffee_maker</tt> you can upload the contents of the tarball <strong>into</strong> that folder.</p> <p class="cpg_message_validation">To make this absolutely clear: you <strong>mustn't</strong> rename the folder a plugin resides in at will, and you mustn't name it as you like when using subversion checkouts. The code of the plugin usually contains hard-coded reference to the folder it resides in, so you need to strictly obey to the naming scheme. Your gallery's visitors won't notice anyway, so why should you care how the name of a particular plugin is. The naming scheme is case-sensitive (i.e. capitalization <strong>does</strong> matter).</p> Need more examples? Here are some examples from real world plugins: <table border="0" cellspacing="0" cellpadding="0" class="cpg_zebra"> <tr> <th valign="top" align="left">Name</th> <th valign="top" align="left">Web SVN</th> <th valign="top" align="left">Tarball download</th> <th valign="top" align="left">Folder name</th> </tr> <tr> <td>BBcode-control</td> <td class="smallcode"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/bbcode_control/">[...]coppermine/branches/cpg1.5.x/plugins/bbcode_control/</a></td> <td class="smallcode"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/bbcode_control.tar.gz?view=tar">[...]/coppermine/branches/cpg1.5.x/plugins/bbcode_control.tar.gz?view=tar</a></td> <td class="smallcode important">bbcode_control</td> </tr> <tr> <td>EnlargeIt!</td> <td class="smallcode"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/enlargeit/">[...]coppermine/branches/cpg1.5.x/plugins/enlargeit/</a></td> <td class="smallcode"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/enlargeit.tar.gz?view=tar">[...]/coppermine/branches/cpg1.5.x/plugins/enlargeit.tar.gz?view=tar</a></td> <td class="smallcode important">enlargeit</td> </tr> <tr> <td>Show all videos in flash player</td> <td class="smallcode"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/video2flash_ffmpeg/">[...]coppermine/branches/cpg1.5.x/plugins/video2flash_ffmpeg/</a></td> <td class="smallcode"><a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/branches/cpg1.5.x/plugins/video2flash_ffmpeg.tar.gz?view=tar">[...]/coppermine/branches/cpg1.5.x/plugins/video2flash_ffmpeg.tar.gz?view=tar</a></td> <td class="smallcode important">video2flash_ffmpeg</td> </tr> </table> You get the point, don't you? It's absolutely mandatory to put the content of the tarball you download into a sub-folder of your plugin folder that is spelled exactly in the way that the folder in the subversion repository has. </div> </div> <a name="dev_subversion_checking_out"></a><h2>Checking out<a href="#dev_subversion_checking_out" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <div class="indent"> <p>The term "checkout" actually stands for "download the files from the repository to your local (working) copy on your client".</p> <a name="dev_subversion_checking_out_entire"></a><h3>Checking out the entire repository<a href="#dev_subversion_checking_out_entire" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p> svn co https://coppermine.svn.sourceforge.net/svnroot/coppermine coppermine</p> <a name="dev_subversion_checking_out_particular_package"></a><h3>Checking out a particular Package<a href="#dev_subversion_checking_out_particular_package" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>Users interessted in the mainstream development should check out the sub-folders of the "trunk"-folder. For cpg1.5.x, you should check out <tt class="code">https://coppermine.svn.sourceforge.net/svnroot/coppermine/trunk/cpg1.5.x/</tt></p> <a name="dev_subversion_checking_out_particular_file"></a><h3>Checking out a particular file<a href="#dev_subversion_checking_out_particular_file" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>If you're interessted in just one particular file (e.g. a language file that didn't exist when you downloaded your coppermine package), you're welcome to use the <a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/" rel="external" class="external">webSVN interface provided by sourceforge.net</a>. Just navigate to the file you want and use the download link there.</p> <a name="dev_subversion_checking_out_refering"></a><h3>Refering to files downloaded from the subversion repository<a href="#dev_subversion_checking_out_refering" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>If you are using a subersion checkout for whatever reason and you're posting on the Coppermine support board, do not refer to the Coppermine version number from the <a href="#dev_subversion_fileheaders">file header</a> of the file(s) that you checked out, but refer to the <a href="#dev_subversion_revision">revision number</a> instead.</p> </div> <a name="dev_subversion_download"></a><h2>Is there no single package that I could download instead?<a href="#dev_subversion_download" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <p>Many end users complain that this sounds too complicated - they ask for a single file that they could download. You have to understand that there <em>are</em> packages for end users - you can get them from <a href="https://sourceforge.net/projects/coppermine/files/">the "official" downloads section of the project</a>: download the most recent stable release! Using subversion to check out the development version is only meant for experienced users who are eager to test the unsupported development version. Consider the effort needed to check out using subversion as a ticket that allows you to get the cutting edge of Coppermine. Bottom line: no, there is no single file that you could download instead of checking out the repository.</p> <div class="indent"> <a name="dev_subversion_download_tarball"></a><h3>Download Tarball archives<a href="#dev_subversion_download_tarball" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>However, starting only recently (as of 2008-08-28), SourceForge (who are hosting "our" subversion repository) have added a new feature to their web svn: you can download a tarball, which in the end is a snapshot of the current version inside the subversion repository. You can find a link to that tarball at the very bottom of the web svn screen. For the actual cpg1.5.x-trunk, the link to that tarball would be <a href="http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/cpg1.5.x.tar.gz?view=tar">http://coppermine.svn.sourceforge.net/viewvc/coppermine/trunk/cpg1.5.x.tar.gz?view=tar</a>. However, the notes on the <a href="testing.htm">testing section of the documentation</a> apply to that tarball just as well as for the rest of the subversion checkout: use for development and evaluation purposes only - no support given. You do not have permission to ask questions related to it on the coppermine support board.</p> </div> <a name="dev_subversion_dev-only"></a><h2>Developers-only<a href="#dev_subversion_dev-only" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <div class="indent"> <p>Don't be afraid that there is some special magic or hidden password stuff if you want to perform a checkout: anybody can check out (i.e. download) from the SVN repository. Active Coppermine developers can additionally write their changes back from their local working copy to the repository - this is named "checking in" or "committing". Regular users (non-developers) don't need to worry about passwords - they can't write back their suggested changes to the repository. If you (as non-developer) want to propose code changes, use the forum and post your proposals.</p> <a name="dev_subversion_checkout_checkin"></a><h3>Check out before checking in<a href="#dev_subversion_checkout_checkin" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>To make sure that changes made by other developers don't get lost you (as Coppermine developer) should always perform a checkout (update) before checking in.</p> <a name="dev_subversion_commit"></a><h3>Committing your code<a href="#dev_subversion_commit" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <p>When using the Windows-driven subversion client tortoise, simply right-click on folder that represents the root folder of your local working copy and choose "commit" from the context menu to upload your changes to the repository.</p> <a name="dev_subversion_changelog"></a><h3>Changelog<a href="#dev_subversion_changelog" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <div class="indent"> <p>The changelog is meant to be a documentation of the added features and fixes that went into the release as well as a good list of improvements. This way, we can make updating more attractive to end users, as they would have to rely on our word that the new version is better than the old one - the improvements and added features should all go into the changelog in reverse chronological order, with the oldest record at the very bottom and the newest record at the top.</p> <p>This being said: all non-trivial commits performed against the subversion repository should be documented as well by a corresponding changelog record that summarizes what your commit is meant to do.</p> <p>The changelog file resides within the root folder of each coppermine package and is named <tt class="code">CHANGELOG.txt</tt>.</p> <p>The changelog format is structured in a self-explanatory way, so here's just a short summary how each line is composed: <a name="dev_subversion_changelog_date"></a><h4>Date<a href="#dev_subversion_changelog_date" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h4> Use the international scientific notation YYYY-MM-DD to allow easy sorting <a name="dev_subversion_changelog_type"></a><h4>Commit type<a href="#dev_subversion_changelog_type" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h4> Use a token from the list in square brackets that explains what type of commit you have performed. As of now, the following tokens exist: <ul> <li><strong>[A]</strong> = Added new feature</li> <li><strong>[B]</strong> = Bugfix (fix something that wasn't working as expected)</li> <li><strong>[C]</strong> = Cosmetical fix (layout, typo etc.)</li> <li><strong>[D]</strong> = Documentation improvements</li> <li><strong>[M]</strong> = Maintenance works</li> <li><strong>[O]</strong> = Optimization of code</li> <li><strong>[S]</strong> = Security fix (issues that are related to security)</li> </ul> <a name="dev_subversion_changelog_text"></a><h4>Explanatory text<a href="#dev_subversion_changelog_text" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h4> Text that explains your actual commit. When refering to a bug brought up on the forum, refere to the thread ID there. <a name="dev_subversion_changelog_name"></a><h4>Developer name<a href="#dev_subversion_changelog_name" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h4> Add your name or nickname in curly braces <p>It's <strong>mandatory</strong> to edit the changelog (even when contributing minor fixes or features). Please try to remember updating the changelog when commiting.</p> <p>Plugin authors are encouraged to maintain a changelog file for their plugin as well, at least if you plan to release your plugin publicly.</p> </div> <a name="dev_subversion_write_access"></a><h3>Obtaining write access<a href="#dev_subversion_write_access" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> As suggested initially on this page, the subversion repository is meant as a tool for the developers to maintain their code changes. Only developers of the coppermine project who have explicitely been allowed to have subversion write access can change the files in the repository. It is not possible to assign subversion write access for particular sub-folders of the repository.<br /> Subsequently, when you have a contribution to make (i.e. if you improve one or more files that reside in the repository or if you have created something new that belongs into the repository in your opinion), post your suggestions on the coppermine support board. If you can't post in a sub-board where your contribution belongs to in your opinion, post it in the corresponding support board - a moderator will move your posting accordingly if applicable.<br /> Subversion write access is only being granted to Coppermine dev team members. The Coppermine project manager then needs your Unix nickname name on sourceforge.net to assign subversion access for you. </div> <a name="dev_subversion_step-by-step"></a><h2>Step by step<a href="#dev_subversion_step-by-step" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <div class="indent"> <p>We will provide a short step-by-step guide how to check out the mainstream cpg1.5.x repository using the Windows-client TortoiseSVN. Please understand though that this goes unsupported; please don't ask questions about it on Coppermine's support forum.</p> <a name="dev_subversion_client-download"></a><h3>Download the client application<a href="#dev_subversion_client-download" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <ul> <li>Download the most recent stable version of the <a href="#dev_subversion_software">TortoiseSVN</a>.</li> <li>After the download has finished, start the install by double-clicking the installer you just downloaded</li> <li>Follow the steps of the installer</li> <li>Reboot your PC once the installer has been run successfully</li> </ul> <a name="dev_subversion_initial_checkout"></a><h3>Initial checkout<a href="#dev_subversion_initial_checkout" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h3> <ul> <li>After the reboot, create a folder on your PC that will later contain your local copy. You will need approximately 25 MB of hard disk space. The location of the folder doesn't matter. In this example, we will create it within c:\my_svn_checkouts\, naming the folder <tt class="code">cpg1.5.x</tt>. Subsequently, we will have an empty folder c:\my_svn_checkouts\cpg1.5.x\</li> <li>Right-click on the newly created folder</li> <li>From the context menu, choose <tt class="code">SVN Checkout...</tt></li> <li>In the field "URL of the repository", enter the URL of the folder you want to check out. For the mainstream cpg1.5.x-folder, enter <tt class="code">https://coppermine.svn.sourceforge.net/svnroot/coppermine/trunk/cpg1.5.x</tt></li> <li>Leave all other settings as they are (<tt class="code">Only check out the top folder</tt> = off; <tt class="code">Omit externals</tt> = off; <tt class="code">Revision</tt> = <tt class="code">HEAD revision</tt>)</li> <li>Click "OK"</li> <li><img src="images/subversion_checkout_success.jpg" width="400" height="211" border="0" alt="" title="Checkout progress" align="right" />A dialog will pop up that shows the progress of the initial check out. Depending on your connection speed, this will take some time - during the initial check out, all files within the repository are being downloaded.<br />As long as the download continues, the OK button will be greyed out (you could cancel at any time though). Once the checkout is finished, the OK button will get clickable.</li> <li>Now the full source code should reside as a working copy on your hard drive. You can now just go ahead and upload all of the files to your testbed or even set up your testbed up to just use the folder you checked out to. If you're going to upload the files to your testbed, you might want to get rid of all the extra subversion files first though (they won't hurt, but there is a lot of those small subversion files that will just take longer to transfer to your testbed using FTP). To get rid of the surplus subversion files (i.e. the files and folders that are used by the sbuversion client to keep track of changes), just copy the entire folder where you have checked out to to a temporary folder, then perform a search for files/folders named "<tt class="code">.svn</tt>" and then delete all those files (i.e. the files that turn up as a search result) from the temporary folder. The files that remain will be the actual coppermine source code without the surplus SVN files. In fact, you can use the files and perform a regular install as if it was an actual coppermine package, so in fact the <a href="install.htm">install instructions from this documentation</a> apply.</li> </ul> </div> <a name="dev_subversion_revision"></a><h2>Revisions<a href="#dev_subversion_revision" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> <p>As you can see by looking at any coppermine source code file, there is a reference to a revision number in each file (deliberately added). This is supposed to help developers mostly, as you can clearly determine wether files are up-to-date.</p> <p>Additionally, the revision numbers are being (ab)used to track files when <a href="upgrading.htm#upgrade">upgrading</a>; the <a href="upgrading.htm#versioncheck">versioncheck mechanism</a> compares file revisions as well, so let's explain what the revisions are for.</p> <p>Each time a developer (who has <em>write</em> access to the subversion repository) committs something (adding a new file to the svn counts as well as committing as deleting a file or editing the contents of a file), a the revision number of that repository counts up. Whenever a file is affected in the commit, it will "inherit" the revision count from the commit operation.</p> <p class="cpg_example">Let's assume that someone starts a new subversion repository. The revision count starts at "1". He then commits three new files to the repository (i.e. he "uploads" those files to the repository) - let's assume that those files are named "a.txt", "b.txt" and "c.txt". This upload operation makes the revision counter increase from 1 to 2. All three files now have revision "2". Then, the developer modifies file "b.txt" and commits his change (the commit will be revision 3). If you look at the files, "a.txt" and "c.txt" will have revision "2", while file "b.txt" has revision 3. Now, another developer comes into play, he edits file "a.txt" and "b.txt" and commits those changes. Revision counter goes to 4, so our files look like this: "a.txt" - rev.4, "b.txt" - rev.4, "c.txt" - rev.2.</p> <p>As you can see from the example, this is a great thing to keep track of file revisions: whenever a file changes, it will get a new revision number.</p> <p>This is great for the developer, but what's the benefit for regular users then? To be able to understand this, you'll have to understand how releases work: the dev team decides that it's time to release a new package, so the packager (the dev team member who is in charge of creating the package for end users) will perform a checkout from the SVN repository to make sure that his local files are up to date. Then he creates an archive and uploads that archive to the downloads section of the coppermine webspace, where the end user can get that package. In each of the files inside the package, the revision numbers still show through, but don't have an impact on the release, so you (the end user) don't need to worry about the revision numbers in the first place - after all, you the package you have downloaded has got a version number, that's all you need to know. However, development continues - developers are still fixing bugs in the repository, so the revision count of the files in the svn repository will increase. There won't be a new package release just because just one file in the repository changed - usually, several changes (=fixes) will be rolled into one when a new package is being released. Now, what's the catch? Well, between official package releases, you can still get the most recent files from the svn repository - that's recommended for users who are concerned about security, but as well if you experience an issue with your gallery and read about a fix on the bugs board that a developer has reported to be fixed in the svn. If you want to get the fix, head over to the web SVN, browse it and get the file that contains the fix. Use it as a replacement for the file on your server that was buggy. If you do that, versioncheck will report your file on the server to be newer than expected (because it actually <strong>is</strong> newer than the file that went into the released package).</p> <a name="dev_subversion_fileheaders"></a><h2>Subversion file headers<a href="#dev_subversion_fileheaders" title="Link to this section"><img src="images/anchor.gif" width="15" height="9" border="0" alt="" /></a></h2> In all textual Coppermine files (i.e. files with the extensions <tt class="code">.php</tt>, <tt class="code">.htm</tt>, <tt class="code">.css</tt>, <tt class="code">.js</tt>, <tt class="code">sql</tt>, <tt class="code">.txt</tt>, <tt class="code">.xml</tt>) there is a subversion header present that is meant to help developers and power users to determine what version and revision number a particular file is. This can be helpfull when troubleshooting as well as in support matters. However, from a technical point of view (as far as the core functionality of your gallery is concerned), the additional subversion file headers are just for information purposes and don't server any technical purpose.<br /> Subsequently: if you're an end user, you can savely remove the subversion file headers from files where this bothers you, e.g. if you want a clean HTML output (code-wise) of your pages you can remove the subversion file header from the HTML template file of your custom theme (<tt class="code">themes/yourtheme/template.html</tt>).<br /> Developers and contributors on the other hand are required to <strong>preserve</strong> the subversion file header or add it when coming up with new files that end up under version control (see "<a href="dev_files.htm#dev_files_adding">Adding files</a>").<br /> The idea behind the subversion file header is that it always get's updated automatically be the subversion software whenever a user with subversion write access committs a file. Think of the lines as placeholders: the subversion keywords <tt class="code">$HeadURL$</tt>, <tt class="code">$Revision$</tt>, <tt class="code">$Date$</tt> get replaced by their actual values - in this document, the equivalents are <tt class="code">$HeadURL: https://coppermine.svn.sourceforge.net/svnroot/coppermine/trunk/cpg1.5.x/docs/fr/dev_subversion.htm $</tt>, <tt class="code">$Revision: 8154 $</tt>, <tt class="code">$Date: 2011-01-02 20:44:22 +0100 (So, 02 Jan 2011) $</tt>. There is no point in manually editing the content of those values - remove the information if you're an end user and it bothers you, but it won't affect your gallery in any way, so it's easier to leave the subversion file headers as they are. <div id="doc_footer"> <div class="doc_info_wrapper"> <span id="doc_last_changed">$LastChangedDate: 2011-01-02 20:44:22 +0100 (So, 02 Jan 2011) $</span> <span id="doc_revision">$Revision: 8154 $</span> </div> </div> </body> </html>