threads / discuss / 21335

[cvsimport] Import CVS repository from a specified date or branch name

Subject: [cvsimport] Import CVS repository from a specified date or branch name

## tl;dr

3 messages between Oct 23, 2009 and Oct 23, 2009.

replies: 2people: 3as markdown or json

Klaus Rödel· Oct 23, 2009, 07:52 UTC · lore
Hello,

I have a very large and old (serveral years) cvs repository and I want to import this in git. For my work it is not nessecary to import all the revision history from the cvs repository. It is engough to import only the revisions from a specified date or branch name of the cvs repo.

Is this possible with git-cvsimport? If yes, how? If no, is it possible to include such a function in the git-cvsimport script?

Thanks for any help.
Greets Klaus
Andreas Schwab· Oct 23, 2009, 20:10 UTC · re: Klaus Rödel · lore

Re: [cvsimport] Import CVS repository from a specified date or branch name

Klaus Rödel <klaus.roedel@vipco.de> writes:
Show 9 quoted lines
> I have a very large and old (serveral years) cvs repository and I want to
> import this in git.
> For my work it is not nessecary to import all the revision history from
> the cvs repository.
> It is engough to import only the revisions from a specified date or branch
> name of the cvs repo.
>
> Is this possible with git-cvsimport?
> If yes, how?

You may be able to do that by passing the right arguments to cvsps. From cvsps --help:

  -d <date1> -d <date2> if just one date specified, show
     revisions newer than date1.  If two dates specified,
     show revisions between two dates.
  -b <branch> restrict output to patch sets affecting history of branch
Andreas.
-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."
Nick Woolley· Oct 23, 2009, 21:38 UTC · re: Klaus Rödel · lore

Re: [cvsimport] Import CVS repository from a specified date or branch name

Klaus Rödel wrote:
Show 8 quoted lines
> I have a very large and old (serveral years) cvs repository and I want
> to import this in git.
> For my work it is not nessecary to import all the revision history from
> the cvs repository.
> It is engough to import only the revisions from a specified date or
> branch name of the cvs repo.
> 
> Is this possible with git-cvsimport?

I'm not certain if it is possible, if it is I suspect it might require invoking cvsps first and then reading in the output generated with git-cvsimport, as Andreas implies.

In any case, the underlying cvsps program is flawed, and in it's current form, although it seems to work ok for simple situations, I know for a fact that didn't faithfully reproduce a rather big old CVS repository I tried it on. So if you're planning on just importing once, and don't need incremental imports, from my experience I'd suggest you'd fare better using cvs2git:

http://cvs2svn.tigris.org/cvs2git.html
Cheers,
N

← back to recent threads