1CVS2GIT(1)                       User Commands                      CVS2GIT(1)
2
3
4

NAME

6       cvs2git - convert a cvs repository into a git repository
7

SYNOPSIS

9       cvs2git [OPTION]... OUTPUT-OPTIONS CVS-REPOS-PATH
10       cvs2git [OPTION]... --options=PATH
11

DESCRIPTION

13       Create  a  new  git repository based on the version history stored in a
14       CVS repository. Each CVS commit will be mirrored in the git repository,
15       including such information as date of commit and id of the committer.
16
17       The  output  of  this  program are a "blobfile" and a "dumpfile", which
18       together can be loaded into a git repository using "git fast-import".
19
20       CVS-REPOS-PATH is the filesystem path of the part of the CVS repository
21       that  you  want to convert.  This path doesn't have to be the top level
22       directory of a CVS repository; it can  point  at  a  project  within  a
23       repository,  in  which  case only that project will be converted.  This
24       path or one of its parent directories has  to  contain  a  subdirectory
25       called CVSROOT (though the CVSROOT directory can be empty).
26
27       It  is  not  possible directly to convert a CVS repository to which you
28       only have remote access, but the FAQ describes tools that may  be  used
29       to create a local copy of a remote CVS repository.
30

OPTIONS

CONFIGURATION VIA OPTIONS FILE

33       --options=path
34              Read  the  conversion options from path instead of from the com‐
35              mand line. This option allows far  more  conversion  flexibility
36              than can be achieved using the command-line alone. See the docu‐
37              mentation for more information. Only the following  command-line
38              options  are  allowed  in combination with --options: -h/--help,
39              --help-passes,     --version,     -v/--verbose,      -q/--quiet,
40              -p/--pass/--passes, --dry-run, --profile, --trunk-only, --encod‐
41              ing, and --fallback-encoding. Options are processed in the order
42              specified on the command line.
43

OUTPUT OPTIONS

45       --blobfile=path
46              Write the "blob" data (containing revision contents) to path.
47
48       --dumpfile=path
49              Write the revision data (branches and commits) to path.
50
51       --dry-run
52              Do not create any output; just print what would happen.
53

CONVERSION OPTIONS

55       --trunk-only
56              Convert only trunk commits, not tags nor branches.
57
58       --encoding=enc
59              Use  encoding  as  the encoding for filenames, log messages, and
60              author names in the CVS repos. This option may be specified mul‐
61              tiple  times,  in  which  case  the encodings are tried in order
62              until      one      succeeds.      Default:      ascii.      See
63              http://docs.python.org/lib/standard-encodings.html for a list of
64              other standard encodings.
65
66       --fallback-encoding=enc
67              If none of the encodings specified with  --encoding  succeed  in
68              decoding  an author name or log message, then fall back to using
69              encoding in lossy 'replace' mode. Use of this option  may  cause
70              information to be lost, but at least it allows the conversion to
71              run to completion. This option only affects the encoding of  log
72              messages  and  author  names;  there is no fallback encoding for
73              filenames. (By using an --options file, it is possible to  spec‐
74              ify a fallback encoding for filenames.) Default: disabled.
75
76       --retain-conflicting-attic-files
77              If  a  file  appears  both  inside  an outside of the CVS attic,
78              retain the attic version in an SVN subdirectory called  'Attic'.
79              (Normally this situation is treated as a fatal error.)
80

SYMBOL HANDLING

82       --symbol-transform=p:s
83              Transform RCS/CVS symbol names before entering them into Subver‐
84              sion.  pattern is  a  Python  regexp  pattern  that  is  matches
85              against  the  entire  symbol  name; replacement is a replacement
86              using Python's regexp reference syntax. You may specify any num‐
87              ber of these options; they will be applied in the order given on
88              the command line.
89
90       --symbol-hints=path
91              Read symbol conversion hints from path. The format  of  path  is
92              the  same  as the format output by --write-symbol-info, namely a
93              text file with four  whitespace-separated  columns:  project-id,
94              symbol,  conversion,  and  parent-lod-name.   project-id  is the
95              numerical ID of the project to which the symbol belongs,  count‐
96              ing  from 0. project-id can be set to '.' if project-specificity
97              is not needed. symbol-name is the name of the symbol being spec‐
98              ified.  conversion specifies how the symbol should be converted,
99              and can be one of the values 'branch', 'tag', or  ´exclude'.  If
100              conversion is '.', then this rule does not affect how the symbol
101              is converted. parent-lod-name is the name  of  the  symbol  from
102              which  this  symbol  should  sprout,  or '.trunk.' if the symbol
103              should sprout from trunk. If parent-lod-name is omitted or  '.',
104              then this rule does not affect the preferred parent of this sym‐
105              bol. The file may contain blank lines or  comment  lines  (lines
106              whose first non-whitespace character is '#').
107
108       --symbol-default=opt
109              Specify  how  to convert ambiguous symbols (those that appear in
110              the CVS archive as both branches and tags). opt must be 'heuris‐
111              tic' (decide how to treat each ambiguous symbol based on whether
112              it was used more often as a branch/tag  in  CVS),  'strict'  (no
113              default;  every  ambiguous  symbol  has  to be resolved manually
114              using  --force-branch,  --force-tag,  or  --exclude),   'branch'
115              (treat  every  ambiguous symbol as a branch), 'tag' (treat every
116              ambiguous symbol as a tag), or 'exclude' (do not convert ambigu‐
117              ous symbols). The default is 'heuristic'.
118
119       --force-branch=regexp
120              Force  symbols  whose names match regexp to be branches.  regexp
121              must match the whole symbol name.
122
123       --force-tag=regexp
124              Force symbols whose names match regexp to be tags.  regexp  must
125              match the whole symbol name.
126
127       --exclude=regexp
128              Exclude branches and tags whose names match regexp from the con‐
129              version. regexp must match the whole symbol name.
130
131       --keep-trivial-imports
132              Do not exclude branches that were only used for a single import.
133              (By  default such branches are excluded because they are usually
134              created by the inappropriate use of cvs import.)
135

SUBVERSION PROPERTIES

137       --username=name
138              Set the default username to name when cvs2svn needs to  generate
139              a  commit  for  which CVS does not record the original username.
140              This happens when a branch or tag is created. The default is  to
141              use no author at all for such commits.
142
143       --auto-props=file
144              Specify  a file in the format of Subversion's config file, whose
145              [auto-props] section can be used to set arbitrary properties  on
146              files  in  the  Subversion  repository based on their filenames.
147              (The [auto-props] section header must be present; other sections
148              of the config file, including the enable-auto-props setting, are
149              ignored.)  Filenames are matched to the filename patterns  case-
150              insensitively.
151
152       --mime-types=file
153              Specify  an  apache-style  mime.types file for setting svn:mime-
154              type.
155
156       --eol-from-mime-type
157              For files that don't have the kb expansion mode but have a known
158              mime  type,  set  the eol-style based on the mime type. For such
159              files, set svn:eol-style to "native" if  the  mime  type  begins
160              with "text/", and leave it unset (i.e., no EOL translation) oth‐
161              erwise. Files with unknown mime types are not affected  by  this
162              option. This option has no effect unless the --mime-types option
163              is also specified.
164
165       --default-eol=style
166              Set svn:eol-style to style for files that  don't  have  the  CVS
167              ´kb'  expansion  mode  and  whose  end-of-line  translation mode
168              hasn't been determined by one of the other options.  style  must
169              be 'binary' (default), 'native', 'CRLF', 'LF', or 'CR'.
170
171       --keywords-off
172              By default, cvs2svn sets svn:keywords on CVS files to "author id
173              date" if the mode of the RCS file in question is either kv,  kvl
174              or unset. If you use the --keywords-off switch, cvs2svn will not
175              set svn:keywords for any file. While this  will  not  touch  the
176              keywords  in  the  contents  of  your files, Subversion will not
177              expand them.
178
179       --keep-cvsignore
180              Include .cvsignore files  in  the  output.  (Normally  they  are
181              unneeded because cvs2svn sets the corresponding svn:ignore prop‐
182              erties.)
183
184       --cvs-revnums
185              Record CVS revision numbers as file properties in the Subversion
186              repository. (Note that unless it is removed explicitly, the last
187              CVS revision number will remain associated with  the  file  even
188              after the file is changed within Subversion.)
189

EXTRACTION OPTIONS

191       --use-cvs
192              Use CVS to extract revision contents. This option is slower than
193              --use-internal-co or --use-rcs.
194
195       --use-rcs
196              Use RCS 'co' to extract revision contents. This option is faster
197              than --use-cvs but fails in some cases.
198
199       --use-external-blob-generator
200              Use an external Python program to extract the file revision con‐
201              tents from the RCS files and output them to the  blobfile.  This
202              option  is  much  faster  than --use-rcs or --use-cvs but leaves
203              keywords unexpanded and requires a separate, seekable blob  file
204              to write to in parallel to the main cvs2git script.
205

ENVIRONMENT OPTIONS

207       --tmpdir=path
208              Set  the  path to use for temporary data. Default is a directory
209              called cvs2svn-tmp under the current directory.
210
211       --co=path
212              Path to the co program. (co is needed if the --use-rcs option is
213              used.)
214
215       --cvs=path
216              Path  to the cvs program. (cvs is needed if the --use-cvs option
217              is used.)
218

PARTIAL CONVERSIONS

220       --pass=pass
221              Execute only pass pass of the conversion. pass can be  specified
222              by name or by number (see --help-passes).
223
224       -p [start]:[end], --passes=[start]:[end]
225              Execute  passes start through end of the conversion (inclusive).
226              start and end can be specified by name or by number (see --help-
227              passes). If start or end is missing, it defaults to the first or
228              last pass, respectively. For this to  work  the  earlier  passes
229              must  have been completed before on the same CVS repository, and
230              the generated data files must be in the temporary directory (see
231              --tmpdir).
232

INFORMATION OPTIONS

234       --version
235              Print the version number.
236
237       -h, --help
238              Print the usage message and exit with success.
239
240       --help-passes
241              Print  the  numbers  and names of the conversion passes and exit
242              with success.
243
244       --man  Output the unix-style manpage for this program to standard  out‐
245              put.
246
247       -v, --verbose
248              Print  more information while running. This option may be speci‐
249              fied twice to output voluminous debugging information.
250
251       -q, --quiet
252              Print less information while running. This option may be  speci‐
253              fied twice to suppress all non-error output.
254
255       --write-symbol-info=path
256              Write  to  path symbol statistics and information about how sym‐
257              bols were converted during CollateSymbolsPass.
258
259       --skip-cleanup
260              Prevent the deletion of temporary files.
261
262       --profile
263              Profile with 'cProfile' (into file cvs2svn.cProfile).
264

FILES

266       A directory called cvs2svn-tmp (or the directory specified by --tmpdir)
267       is used as scratch space for temporary data files.
268

AUTHORS

270       Main authors are:
271       C. Michael Pilato <cmpilato@collab.net>
272       Greg Stein <gstein@lyra.org>
273       Branko Čibej <brane@xbc.nu>
274       Blair Zajac <blair@orcaware.com>
275       Max Bowsher <maxb@ukf.net>
276       Brian Fitzpatrick <fitz@red-bean.com>
277       Tobias Ringström <tobias@ringstrom.mine.nu>
278       Karl Fogel <kfogel@collab.net>
279       Erik Hülsmann <e.huelsmann@gmx.net>
280       David Summers <david@summersoft.fay.ar.us>
281       Michael Haggerty <mhagger@alum.mit.edu>
282
283       Manpage  was  written  for  the Debian GNU/Linux system by Laszlo 'GCS'
284       Boszormenyi <gcs@lsc.hu> (but may be used by others).
285

SEE ALSO

287       cvs(1), git(1), git-fast-import(1)
288
289
290
291Version 2.4.0-dev                Feb 02, 2011                       CVS2GIT(1)
Impressum