source: tailor/README @ 177

Revision 177, 4.5 KB checked in by lele@…, 8 years ago (diff)

Other little tweaks at the README

Line 
1About
2=====
3
4tailor.py is a tool to migrate changesets between CVS, Subversion, and
5darcs repositories.
6
7This script makes it easier to keep the upstream changes merged in
8a branch of a product, storing needed information such as the upstream
9URI and revision in special properties on the branched directory.
10
11
12Installation
13============
14
15tailor.py is written in Python, and thus Python must be installed on
16your system to use it. Since it relays on external tools to do the
17real work such as `cvs`, `darcs` and `svn`, they need to be installed
18as well.
19
20Make tailor.py executable::
21
22 $ chmod +x tailor.py
23
24You can either run tailor.py where it is currently located, or move it
25along with the vcpx directory to a location in your PATH.
26
27
28Examples
29========
30
311. Bootstrap a new taylored project, starting at upstream revision 10::
32
33  $ tailor.py -b -s svn -R http://svn.server/Product -r 10 ~/darcs/MyProduct
34
352. Bootstrap a new product, fetching from CVS and storing under SVN:
36   this will create the directory "~/svnwc/cmfcore"; "~/svnwc" must be
37   already under SVN::
38
39  $ tailor.py --source-kind cvs --target-kind svn --bootstrap \
40              --repository :pserver:cvs.zope.org:/cvs-repository \
41              --module CMF/CMFCore ~/svnwc/cmfcore
42 
433. Showing each command bootstrap a new DARCS repos in
44   "~/darcs/cmftopic" under which the upstream module will be
45   extracted as "CMFTopic" (ie, the last component of the module
46   name)::
47
48  $ tailor.py -D -b -R :pserver:anonymous@cvs.zope.org:/cvs-repository/ \
49              -m CMF/CMFTopic ~/darcs/cmftopic
50             
514. Merge upstream changes since last update/bootstrap::
52
53  $ tailor.py ~/svnwc/MyProduct
54
55
56Tailor's metadata
57=================
58
59To do its work, tailor needs some information about your source tree,
60such as the upstream repository URL and the current revision of the
61sources on your harddisk.
62
63In the simpler case, tailor keeps this information in a file called
64`tailor.info`, one for each tailored project, that is a very simple
65text document, with the following information, one per line:
66
671. Upstream repository kind (either "cvs", "darcs" or "svn)
682. Target repository kind (the same as above)
693. The name of the "module" that's been tailored
704. The URL of the upstream repository (that may not be an URL, for cvs...)
715. The current revision, from the upstream point of view, of the sources
72
73This is everything tailor needs, to be able to keep going from where it
74left last time.
75
76
77Config file format
78------------------
79
80When your project is composed by multiple upstream modules, it is
81easier to collect such information in a single file. This is done by
82specifying the `--configfile` option with a file name as argument. In
83this case, tailor will read/write the above information from a
84standard Python dictionary stored in the given file.
85
86The dictionary is keyed on the relative position of each project, and
87each entry carries the same information described above.
88
89Here's an example config file entry::
90
91 {'plone/atcontenttypes': {'module': 'ATContentTypes',
92                           'source_kind': 'cvs',
93                           'subdir': 'ATContentTypes',
94                           'target_kind': 'darcs',
95                           'upstream_repos': ':ext:cvs.sourceforge.net:/cvsroot/collective',
96                           'upstream_revision': '2004-11-24 19:42:06 by ctheune'}}
97
98By convention, config files are named with the extension ".tailor",
99but this is not enforced.
100
101In the example above, 'plone/atcontenttypes' is a directory where the
102target source will be stored. The keys such 'module', 'source_kind',
103etc correspond to options of the same name.
104
105When using a config file, tailor will perform its job on each project
106contained in the dictionary.
107
108
109Further help
110============
111
112See the output of tailor.py -h for some further tips.  There's also a
113`wiki page`_ that may give you some other hints.
114
115.. _wiki page:
116   http://www.scannedinavian.org/DarcsWiki/ConvertingFromSubversion
117
118I will be more than happy to answer any doubt, question or suggestion
119you may have on it. I'm usually hanging as "lelit" on the IRC channel
120devoted to darcs on the `freenode.net` network. Do not hesitate to
121contact me either by email or chatting there.
122
123
124Author
125======
126
127Lele Gaifax <lele@nautilus.homeip.net>
128
129
130About this document
131===================
132
133This document and most of the internal documention use the
134reStructuredText format so that it can be easily converted into other
135formats, such as HTML.  For more information about this, please see:
136
137  http://docutils.sourceforge.net/rst.html
138
139
140.. vim:ft=rest
141.. Local Variables:
142.. mode: rst
143.. End:
Note: See TracBrowser for help on using the repository browser.