1 <!DOCTYPE html PUBLIC
"-//W3C//DTD XHTML 1.1//EN"
2 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
3 <html xmlns=
"http://www.w3.org/1999/xhtml" xml:
lang=
"en">
5 <meta http-equiv=
"Content-Type" content=
"text/html; charset=UTF-8" />
6 <meta name=
"generator" content=
"AsciiDoc 8.2.5" />
7 <style type=
"text/css">
9 p
, li
, dt
, dd
, div
, pre
, h1
, h2
, h3
, h4
, h5
, h6
{
11 border: 1px solid red;
16 margin: 1em 5% 1em 5%;
21 text-decoration: underline
;
39 h1
, h2
, h3
, h4
, h5
, h6
{
41 font-family: sans-serif
;
48 border-bottom: 2px solid silver
;
66 border: 1px solid silver
;
81 font-family: sans-serif
;
88 font-family: sans-serif
;
92 font-family: sans-serif
;
94 border-top: 2px solid silver
;
100 padding-bottom: 0.5em;
104 padding-bottom: 0.5em;
108 div
.tableblock
, div
.imageblock
, div
.exampleblock
, div
.verseblock
,
109 div
.quoteblock
, div
.literalblock
, div
.listingblock
, div
.sidebarblock
,
110 div
.admonitionblock
{
113 margin-bottom: 1.5em;
115 div
.admonitionblock
{
117 margin-bottom: 2.5em;
120 div
.content
{ /* Block element content. */
124 /* Block element titles. */
125 div
.title
, caption
.title
{
126 font-family: sans-serif
;
130 margin-bottom: 0.5em;
136 td div
.title:first-child
{
139 div
.content div
.title:first-child
{
142 div
.content
+ div
.title
{
146 div
.sidebarblock
> div
.content
{
148 border: 1px solid silver
;
155 div
.listingblock
> div
.content
{
156 border: 1px solid silver
;
161 div
.quoteblock
> div
.content
{
168 div
.verseblock
+ div
.attribution
{
172 div
.admonitionblock
.icon
{
176 text-decoration: underline
;
178 padding-right: 0.5em;
180 div
.admonitionblock td
.content
{
182 border-left: 2px solid silver
;
185 div
.exampleblock
> div
.content
{
186 border-left: 2px solid silver
;
190 div
.verseblock div
.content
{
194 div
.imageblock div
.content
{ padding-left: 0; }
195 div
.imageblock img
{ border: 1px solid silver
; }
196 span
.image img
{ border-style: none
; }
200 margin-bottom: 0.8em;
212 list-style-position: outside
;
215 list-style-type: lower-alpha
;
218 div
.tableblock
> table
{
219 border: 3px solid
#527bbd;
222 font-family: sans-serif
;
231 margin-bottom: 0.8em;
239 padding-right: 0.8em;
246 div#footer-badges
{ display: none
; }
251 font-family: sans-serif
;
255 margin-bottom: 0.1em;
258 div
.toclevel1
, div
.toclevel2
, div
.toclevel3
, div
.toclevel4
{
274 include1::./stylesheets
/xhtml11-manpage
.css
[]
275 /* Workarounds for IE6's broken and incomplete CSS2. */
277 div
.sidebar-content
{
279 border: 1px solid silver
;
282 div
.sidebar-title
, div
.image-title
{
283 font-family: sans-serif
;
286 margin-bottom: 0.5em;
289 div
.listingblock div
.content
{
290 border: 1px solid silver
;
295 div
.quoteblock-content
{
299 div
.exampleblock-content
{
300 border-left: 2px solid silver
;
304 /* IE6 sets dynamically generated links as visited. */
305 div#toc
a:visited
{ color: blue
; }
307 <title>git-cvsimport(
1)
</title>
312 git-cvsimport(
1) Manual Page
315 <div class=
"sectionbody">
317 Salvage your data out of another SCM people love to hate
322 <div class=
"sectionbody">
323 <div class=
"verseblock">
324 <div class=
"content"><em>git cvsimport
</em> [-o
<branch-for-HEAD
>] [-h] [-v] [-d
<CVSROOT
>]
325 [-A
<author-conv-file
>] [-p
<options-for-cvsps
>] [-P
<file
>]
326 [-C
<git_repository
>] [-z
<fuzz
>] [-i] [-k] [-u] [-s
<subst
>]
327 [-a] [-m] [-M
<regex
>] [-S
<regex
>] [-L
<commitlimit
>]
328 [-r
<remote
>] [-R] [
<CVS_module
>]
</div></div>
330 <h2 id=
"_description">DESCRIPTION
</h2>
331 <div class=
"sectionbody">
332 <div class=
"para"><p>Imports a CVS repository into git. It will either create a new
333 repository, or incrementally import into an existing one.
</p></div>
334 <div class=
"para"><p>Splitting the CVS log into patch sets is done by
<em>cvsps
</em>.
335 At least version
2.1 is required.
</p></div>
336 <div class=
"para"><p><strong>WARNING:
</strong> for certain situations the import leads to incorrect results.
337 Please see the section
<a href=
"#issues">ISSUES
</a> for further reference.
</p></div>
338 <div class=
"para"><p>You should
<strong>never
</strong> do any work of your own on the branches that are
339 created by
<em>git cvsimport
</em>. By default initial import will create and populate a
340 "master" branch from the CVS repository's main branch which you're free
341 to work with; after that, you need to
<em>git merge
</em> incremental imports, or
342 any CVS branches, yourself. It is advisable to specify a named remote via
343 -r to separate and protect the incoming branches.
</p></div>
344 <div class=
"para"><p>If you intend to set up a shared public repository that all developers can
345 read/write, or if you want to use
<a href=
"git-cvsserver.html">git-cvsserver(
1)
</a>, then you
346 probably want to make a bare clone of the imported repository,
347 and use the clone as the shared repository.
348 See
<a href=
"gitcvs-migration.html">gitcvs-migration(
7)
</a>.
</p></div>
350 <h2 id=
"_options">OPTIONS
</h2>
351 <div class=
"sectionbody">
352 <div class=
"vlist"><dl>
358 Verbosity: let
<em>cvsimport
</em> report what it is doing.
366 The root of the CVS archive. May be local (a simple path) or remote;
367 currently, only the :local:, :ext: and :pserver: access methods
368 are supported. If not given,
<em>git cvsimport
</em> will try to read it
369 from
<tt>CVS/Root
</tt>. If no such file exists, it checks for the
370 <tt>CVSROOT
</tt> environment variable.
378 The CVS module you want to import. Relative to
<CVSROOT
>.
379 If not given,
<em>git cvsimport
</em> tries to read it from
380 <tt>CVS/Repository
</tt>.
384 -C
<target-dir
>
388 The git repository to import to. If the directory doesn't
389 exist, it will be created. Default is the current directory.
397 The git remote to import this CVS repository into.
398 Moves all CVS branches into remotes/
<remote
>/
<branch
>
399 akin to the way
<em>git clone
</em> uses
<em>origin
</em> by default.
403 -o
<branch-for-HEAD
>
407 When no remote is specified (via -r) the
<em>HEAD
</em> branch
408 from CVS is imported to the
<em>origin
</em> branch within the git
409 repository, as
<em>HEAD
</em> already has a special meaning for git.
410 When a remote is specified the
<em>HEAD
</em> branch is named
411 remotes/
<remote
>/master mirroring
<em>git clone
</em> behaviour.
412 Use this option if you want to import into a different
415 <div class=
"para"><p>Use
<em>-o master
</em> for continuing an import that was initially done by
416 the old cvs2git tool.
</p></div>
423 Import-only: don't perform a checkout after importing. This option
424 ensures the working directory and index remain untouched and will
425 not create them if they do not exist.
433 Kill keywords: will extract files with
<em>-kk
</em> from the CVS archive
434 to avoid noisy changesets. Highly recommended, but off by default
435 to preserve compatibility with early imported trees.
443 Convert underscores in tag and branch names to dots.
451 Substitute the character
"/" in branch names with
<subst
>
455 -p
<options-for-cvsps
>
459 Additional options for cvsps.
460 The options
<em>-u
</em> and
<em>-A
</em> are implicit and should not be used here.
462 <div class=
"para"><p>If you need to pass multiple options, separate them with a comma.
</p></div>
469 Pass the timestamp fuzz factor to cvsps, in seconds. If unset,
470 cvsps defaults to
300s.
474 -P
<cvsps-output-file
>
478 Instead of calling cvsps, read the provided cvsps output file. Useful
479 for debugging or when cvsps is being handled outside cvsimport.
487 Attempt to detect merges based on the commit message. This option
488 will enable default regexes that try to capture the source
489 branch name from the commit message.
497 Attempt to detect merges based on the commit message with a custom
498 regex. It can be used with
<em>-m
</em> to enable the default regexes
499 as well. You must escape forward slashes.
501 <div class=
"para"><p>The regex must capture the source branch name in $
1.
</p></div>
502 <div class=
"para"><p>This option can be used several times to provide several detection regexes.
</p></div>
509 Skip paths matching the regex.
517 Import all commits, including recent ones. cvsimport by default
518 skips commits that have a timestamp less than
10 minutes ago.
526 Limit the number of commits imported. Workaround for cases where
527 cvsimport leaks memory.
531 -A
<author-conv-file
>
535 CVS by default uses the Unix username when writing its
536 commit logs. Using this option and an author-conv-file
539 <div class=
"listingblock">
540 <div class=
"content">
541 <pre><tt> exon=Andreas Ericsson
<ae@op5.se
>
542 spawn=Simon Pawn
<spawn@frog-pond.org
>
545 <div class=
"para"><p><em>git cvsimport
</em> will make it appear as those authors had
546 their GIT_AUTHOR_NAME and GIT_AUTHOR_EMAIL set properly
548 <div class=
"para"><p>For convenience, this data is saved to
<tt>$GIT_DIR/cvs-authors
</tt>
549 each time the
<em>-A
</em> option is provided and read from that same
550 file each time
<em>git cvsimport
</em> is run.
</p></div>
551 <div class=
"para"><p>It is not recommended to use this feature if you intend to
552 export changes back to CVS again later with
553 <em>git cvsexportcommit
</em>.
</p></div>
560 Generate a
<tt>$GIT_DIR/cvs-revisions
</tt> file containing a mapping from CVS
561 revision numbers to newly-created Git commit IDs. The generated file
562 will contain one line for each (filename, revision) pair imported;
563 each line will look like
565 <div class=
"listingblock">
566 <div class=
"content">
567 <pre><tt>src/widget.c
1.1 1d862f173cdc7325b6fa6d2ae1cfd61fd1b512b7
</tt></pre>
569 <div class=
"para"><p>The revision data is appended to the file if it already exists, for use when
570 doing incremental imports.
</p></div>
571 <div class=
"para"><p>This option may be useful if you have CVS revision numbers stored in commit
572 messages, bug-tracking systems, email archives, and the like.
</p></div>
579 Print a short usage message and exit.
584 <h2 id=
"_output">OUTPUT
</h2>
585 <div class=
"sectionbody">
586 <div class=
"para"><p>If
<em>-v
</em> is specified, the script reports what it is doing.
</p></div>
587 <div class=
"para"><p>Otherwise, success is indicated the Unix way, i.e. by simply exiting with
588 a zero exit status.
</p></div>
590 <h2 id=
"issues">ISSUES
</h2>
591 <div class=
"sectionbody">
592 <div class=
"para"><p>Problems related to timestamps:
</p></div>
593 <div class=
"ilist"><ul>
596 If timestamps of commits in the CVS repository are not stable enough
597 to be used for ordering commits changes may show up in the wrong
603 If any files were ever
"cvs import"ed more than once (e.g., import of
604 more than one vendor release) the HEAD contains the wrong content.
609 If the timestamp order of different files cross the revision order
610 within the commit matching time window the order of commits may be
615 <div class=
"para"><p>Problems related to branches:
</p></div>
616 <div class=
"ilist"><ul>
619 Branches on which no commits have been made are not imported.
624 All files from the branching point are added to a branch even if
630 This applies to files added to the source branch
<strong>after
</strong> a daughter
631 branch was created: if previously no commit was made on the daughter
632 branch they will erroneously be added to the daughter branch in git.
636 <div class=
"para"><p>Problems related to tags:
</p></div>
637 <div class=
"ilist"><ul>
640 Multiple tags on the same revision are not imported.
644 <div class=
"para"><p>If you suspect that any of these issues may apply to the repository you
645 want to import consider using these alternative tools which proved to be
646 more stable in practice:
</p></div>
647 <div class=
"ilist"><ul>
650 cvs2git (part of cvs2svn),
<tt>http://cvs2svn.tigris.org
</tt>
655 parsecvs,
<tt>http://cgit.freedesktop.org/~keithp/parsecvs
</tt>
660 <h2 id=
"_author">Author
</h2>
661 <div class=
"sectionbody">
662 <div class=
"para"><p>Written by Matthias Urlichs
<smurf@smurf.noris.de
>, with help from
663 various participants of the git-list
<git@vger.kernel.org
>.
</p></div>
665 <h2 id=
"_documentation">Documentation
</h2>
666 <div class=
"sectionbody">
667 <div class=
"para"><p>Documentation by Matthias Urlichs
<smurf@smurf.noris.de
>.
</p></div>
669 <h2 id=
"_git">GIT
</h2>
670 <div class=
"sectionbody">
671 <div class=
"para"><p>Part of the
<a href=
"git.html">git(
1)
</a> suite
</p></div>
674 <div id=
"footer-text">
675 Last updated
2010-
09-
18 23:
56:
38 UTC