[ PDF Version ]
Last Updated 03 Oct 2011
The following is a quick guide to using Subversion to
maintain the FLTK code.
Contents
If you are already familiar with the CVS software, you will
find that Subversion is very similar. You'll use the
svn command instead of cvs, and if you set
your CVSEDITOR environment variable, just set the
SVN_EDITOR environment variable to the same thing. The
following table maps CVS commands to Subversion:
| CVS Command |
Subversion Command |
cvs -d repos get fltk |
svn co repos/trunk fltk |
cvs update -dP |
svn update |
cvs add name |
svn add name |
rm -f name
cvs remove name |
svn remove name |
mv name newname
cvs remove name
cvs add newname |
svn move name newname |
cvs commit |
svn commit |
cvs diff |
svn diff |
cvs -d repos get -r foo fltk |
svn co repos/branches/foo fltk
svn co repos/releases/foo fltk |
cvs update -r foo |
svn switch repos/branches/foo
svn switch repos/releases/foo |
cvs tag foo |
svn copy repos/releases/foo |
cvs tag -b foo |
svn copy repos/branches/foo |
repos = username@cvs.sf.net:/cvsroot/fltk for
CVS and https://svn.easysw.com/public/fltk/fltk for Subversion.
To download source code from the ESP Subversion server you
will need the the Subversion (SVN) software for your system.
Most Linux distributions include SVN, and Xcode 1.5 and higher
supports SVN on MacOS X. The SVN software can be found at
the following sites:
http://subversion.tigris.org/
http://tortoisesvn.tigris.org/
The latter site provides a GUI interface for Microsoft
Windows.
To retrieve, or check out, the software, use one of the
following commands:
FLTK 1.1.x:
svn co https://svn.easysw.com/public/fltk/fltk/branches/branch-1.1 fltk-1.1 ENTER
FLTK 2.x (in development):
svn co https://svn.easysw.com/public/fltk/fltk/trunk fltk ENTER
FLTK Applications (in development):
svn co https://svn.easysw.com/public/fltk/applications/trunk fltk ENTER
FLTK Web Site:
svn co https://svn.easysw.com/public/fltk/www/trunk fltk ENTER
To update your local copy of the source code, run the
following command:
svn update ENTER
Note: All of these commands act on your local copy of
the files. Your changes will not be saved on the server until
you commit them.
To add a file, run the following command:
svn add filename ENTER
To move a file, run the following command:
svn move filename newfilename ENTER
To remove a file, run the following command:
svn remove filename ENTER
Don't forget to commit your changes
when you are done.
When adding a source file (Makefile, .cxx, etc), set the properties before commit:
svn add foo.cxx
svn propset svn:eol-style "native" foo.cxx ENTER
svn propset svn:keywords "author date id revision" foo.cxx ENTER
When adding a binary file (eg. images), set the properties before commit:
svn add foo.png
svn propset svn:mime-type "application/octet-stream" foo.png ENTER
Adding a new directory:
mkdir examples ENTER
cp foo.cxx examples/ ENTER
cp bar.cxx examples/ ENTER
svn add examples ENTER
To commit your changes to the server for everyone to see, run
the following command:
svn commit ENTER
To prepare a patch file for submission to the FLTK team, run the
following command:
svn diff >filename.patch ENTER
To list all the tags for fltk:
svn ls http://svn.easysw.com/public/fltk/fltk/tags/ ENTER
To get the revision/date info for a specific fltk release:
svn info http://svn.easysw.com/public/fltk/fltk/tags/release-1.3.0 ENTER
See the changes in a specific revision:
svn diff -c 7496 ENTER
To rename a file:
svn rename old.cxx new.cxx ENTER
To revert a rename (before being committed):
svn revert old.cxx ENTER
svn revert new.cxx ENTER
rm new.cxx ENTER
View the properties on a file
svn pl -v foo.cxx ENTER
|