# Problems with git cvsimport

10 messages from 2007-02-27 to 2007-03-03. Participants: Raimund Bauer, Johannes Schindelin, Junio C Hamano.
Thread: https://gitlist.dev/t/6987

## Raimund Bauer, 2007-02-27 11:13

Subject: Problems with git cvsimport
Message-ID: <001f01c75a60$53443e10$0b0aa8c0@abf.local>
URL: https://gitlist.dev/e/001f01c75a60%2453443e10%240b0aa8c0%40abf.local

```
When trying to cvsimport a project into git, I get an error from cvsps:

bad usage: invalid argument -A

Usage: cvsps [-h] [-x] [-u] [-z <fuzz>] [-g] [-s <range>[,<range>]]
             [-a <author>] [-f <file>] [-d <date1> [-d <date2>]]
             [-b <branch>]  [-l <regex>] [-r <tag> [-r <tag>]]
             [-p <directory>] [-v] [-t] [--norc] [--summary-first]
             [--test-log <captured cvs log file>] [--bkcvs]
             [--no-rlog] [--diff-opts <option string>] [--cvs-direct]
             [--debuglvl <bitmask>] [-Z <compression>] [--root <cvsroot>]
             [<repository>] [-q]

<-- cut option explanation -->

There is cvsps version 2.0rc1 installed on our server (a Suse 9.3 I
believe),
and using git version 1.5.0.2.775.g1a500 (next from a few minutes ago).

Many thanx in advance for any hints on how to make this work

-- 
best regards

  Ray

```

## Johannes Schindelin, 2007-02-27 12:19

Subject: Re: Problems with git cvsimport
Message-ID: <Pine.LNX.4.63.0702271318070.22628@wbgn013.biozentrum.uni-wuerzburg.de>
URL: https://gitlist.dev/e/Pine.LNX.4.63.0702271318070.22628%40wbgn013.biozentrum.uni-wuerzburg.de
In-Reply-To: <001f01c75a60$53443e10$0b0aa8c0@abf.local>

```
Hi,

On Tue, 27 Feb 2007, Raimund Bauer wrote:

> When trying to cvsimport a project into git, I get an error from cvsps:
> 
> bad usage: invalid argument -A

What was your command line?

Ciao,
Dscho

```

## Junio C Hamano, 2007-02-27 12:24

Subject: Re: Problems with git cvsimport
Message-ID: <7vvehng550.fsf@assigned-by-dhcp.cox.net>
URL: https://gitlist.dev/e/7vvehng550.fsf%40assigned-by-dhcp.cox.net
In-Reply-To: <Pine.LNX.4.63.0702271318070.22628@wbgn013.biozentrum.uni-wuerzburg.de>

```
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:

> On Tue, 27 Feb 2007, Raimund Bauer wrote:
>
>> When trying to cvsimport a project into git, I get an error from cvsps:
>> 
>> bad usage: invalid argument -A
>
> What was your command line?

Very good question.  Earlier I was doing grep, and as far as I
can tell, git-cvsimport in Perl _always_ has passed -A to cvsps.

```

## Raimund Bauer, 2007-02-27 13:12

Subject: RE: Problems with git cvsimport
Message-ID: <002001c75a70$f69586e0$0b0aa8c0@abf.local>
URL: https://gitlist.dev/e/002001c75a70%24f69586e0%240b0aa8c0%40abf.local
In-Reply-To: <Pine.LNX.4.63.0702271318070.22628@wbgn013.biozentrum.uni-wuerzburg.de>

```
> > When trying to cvsimport a project into git, I get an error from 
> > cvsps:
> > 
> > bad usage: invalid argument -A
> 
> What was your command line?

The complete command line was

git-cvsimport -d :pserver:ray007@cvs.drupal.org:/cvs/drupal-contrib -C views
-k contributions/modules/views

Leaving out -k doesn't change anything.
And the manpage for git-cvsimport says, option -A is implicit ...

> Ciao,
> Dscho

-- 
best regards

  Ray

```

## Johannes Schindelin, 2007-02-27 16:01

Subject: RE: Problems with git cvsimport
Message-ID: <Pine.LNX.4.63.0702271700300.22628@wbgn013.biozentrum.uni-wuerzburg.de>
URL: https://gitlist.dev/e/Pine.LNX.4.63.0702271700300.22628%40wbgn013.biozentrum.uni-wuerzburg.de
In-Reply-To: <002001c75a70$f69586e0$0b0aa8c0@abf.local>

```
Hi,

On Tue, 27 Feb 2007, Raimund Bauer wrote:

> > > When trying to cvsimport a project into git, I get an error from 
> > > cvsps:
> > > 
> > > bad usage: invalid argument -A
> > 
> > What was your command line?
> 
> The complete command line was
> 
> git-cvsimport -d :pserver:ray007@cvs.drupal.org:/cvs/drupal-contrib -C views
> -k contributions/modules/views

Sorry to have missed that earlier. AFAIR cvsimport _needs_ cvsps 2.1. You 
have version 2.0rc1, which is not sufficient...

Ciao,
Dscho

```

## Raimund Bauer, 2007-02-27 16:15

Subject: RE: Problems with git cvsimport
Message-ID: <002d01c75a8a$8c664dd0$0b0aa8c0@abf.local>
URL: https://gitlist.dev/e/002d01c75a8a%248c664dd0%240b0aa8c0%40abf.local
In-Reply-To: <Pine.LNX.4.63.0702271700300.22628@wbgn013.biozentrum.uni-wuerzburg.de>

```
> > > > When trying to cvsimport a project into git, I get an error from
> > > > cvsps:
> > > > 
> > > > bad usage: invalid argument -A
> > > 
> > > What was your command line?
> > 
> > The complete command line was
> > 
> > git-cvsimport -d 
> :pserver:ray007@cvs.drupal.org:/cvs/drupal-contrib -C 
> > views -k contributions/modules/views
> 
> Sorry to have missed that earlier. AFAIR cvsimport _needs_ 
> cvsps 2.1. You 
> have version 2.0rc1, which is not sufficient...

Thanks, I will make sure we get a new cvsps on the server.

> Ciao,
> Dscho

-- 
best regards

  Ray

```

## Raimund Bauer, 2007-02-28 13:27

Subject: RE: Problems with git cvsimport
Message-ID: <000c01c75b3c$31f91000$0b0aa8c0@abf.local>
URL: https://gitlist.dev/e/000c01c75b3c%2431f91000%240b0aa8c0%40abf.local
In-Reply-To: <Pine.LNX.4.63.0702271700300.22628@wbgn013.biozentrum.uni-wuerzburg.de>

```
> Sorry to have missed that earlier. AFAIR cvsimport _needs_ 
> cvsps 2.1. You 
> have version 2.0rc1, which is not sufficient...

OK, thanks a lot, now that I'm using cvsps especially for git from
http://ydirson.free.fr/en/software/scm/cvsps.html things are looking
a bit better.

There are some modules I can import with relative little noise. Not sure why
I needed to do 'checkout -f' to get all the files in the working directory,
but I got no problem with that.

For some other modules it doesn't work at all.
I.e. trying

$ git cvsimport -d :pserver:ray007@cvs.drupal.org:/cvs/drupal-contrib -C
localizer -a contributions/modules/localizer
Initialized empty Git repository in /home/ray/drupal/modules/localizer/.git/
file 'CHANGELOG.txt; pre_rev:INITIAL; post_rev:1.1; dead:0; branch_point:0
' not found in hash
fatal: refs/heads/origin: not a valid SHA1
fatal: master: not a valid SHA1
warning: You appear to be on a branch yet to be born.
warning: Forcing checkout of HEAD.
fatal: just how do you expect me to merge 0 trees?
checkout failed: 256

Any hint what I have done wrong?

Doing a normal cvs checkout works, trying to do a git-cvsimport in the
checked-out directory fails with the same error again.

For trying out, username=anonymous, password=anonymous should work.
Or to just see what's in the repo, you can have a look at
http://cvs.drupal.org/viewcvs/drupal/contributions/modules/localizer/
to see the repo I tried in the example above.

My perl knowledge is _very_ limited, but I'll have a look at the script too
...

-- 
best regards

  Ray

```

## Johannes Schindelin, 2007-03-03 00:30

Subject: RE: Problems with git cvsimport
Message-ID: <Pine.LNX.4.63.0703030129220.22628@wbgn013.biozentrum.uni-wuerzburg.de>
URL: https://gitlist.dev/e/Pine.LNX.4.63.0703030129220.22628%40wbgn013.biozentrum.uni-wuerzburg.de
In-Reply-To: <000c01c75b3c$31f91000$0b0aa8c0@abf.local>

```
Hi,

On Wed, 28 Feb 2007, Raimund Bauer wrote:

> $ git cvsimport -d :pserver:ray007@cvs.drupal.org:/cvs/drupal-contrib -C
> localizer -a contributions/modules/localizer
> Initialized empty Git repository in /home/ray/drupal/modules/localizer/.git/
> file 'CHANGELOG.txt; pre_rev:INITIAL; post_rev:1.1; dead:0; branch_point:0
> ' not found in hash
> fatal: refs/heads/origin: not a valid SHA1
> fatal: master: not a valid SHA1

This looks to me as if you did not cleanup after failed attempts. I would 
try this in a fresh directory. Actually, I did, and I think it worked, 
too... Latest commit is

commit 8fc1b3decbe961925e3d043f5e03b10e2093d72b
Author: robertogerola <robertogerola>
Date:   Tue Feb 13 13:22:53 2007 +0000

    Updated

Ciao,
Dscho

```

## Raimund Bauer, 2007-03-03 12:31

Subject: RE: Problems with git cvsimport
Message-ID: <1172925097.11109.25.camel@localhost>
URL: https://gitlist.dev/e/1172925097.11109.25.camel%40localhost
In-Reply-To: <Pine.LNX.4.63.0703030129220.22628@wbgn013.biozentrum.uni-wuerzburg.de>

```
On Sat, 2007-03-03 at 01:30 +0100, Johannes Schindelin wrote:
> Hi,
> 
> On Wed, 28 Feb 2007, Raimund Bauer wrote:
> 
> > $ git cvsimport -d :pserver:ray007@cvs.drupal.org:/cvs/drupal-contrib -C
> > localizer -a contributions/modules/localizer
> > Initialized empty Git repository in /home/ray/drupal/modules/localizer/.git/
> > file 'CHANGELOG.txt; pre_rev:INITIAL; post_rev:1.1; dead:0; branch_point:0
> > ' not found in hash
> > fatal: refs/heads/origin: not a valid SHA1
> > fatal: master: not a valid SHA1
> 
> This looks to me as if you did not cleanup after failed attempts. I would 
> try this in a fresh directory. Actually, I did, and I think it worked, 

I always tried with a new directory, that's not the reason.

I've just tried it out on my home-box, which is a ubuntu edgy x86
installation, and git-cvsimport seems to work quite fine here.

On our server, which is a suse 9.3 amd64 installation (with the latest
suse updates for that version), I just can't get it to run. Currently I
wonder how I got _any_ git-cvsimport to work there. Still the same error
256 ...

How do I find out the minimum-version of tools I need to use
git-cvsimport? I already know about cvsps and did install a current
version there, but there seem to be some more dependencies ...
Or could it be a 64-bit issue somewhere?

'make test' says everything is fine.

If you can point me in the some direction on how to debug this, I'll
give it a try, currently I have no clue where to start.

> too... Latest commit is
> 
> commit 8fc1b3decbe961925e3d043f5e03b10e2093d72b
> Author: robertogerola <robertogerola>
> Date:   Tue Feb 13 13:22:53 2007 +0000

Yes, that looks good. Which means something on our server is the reason
for git-cvsimport not working.

Continuing  investigation ...

-- 
best regards

  Ray

```

## Johannes Schindelin, 2007-03-03 16:21

Subject: RE: Problems with git cvsimport
Message-ID: <Pine.LNX.4.63.0703031720290.22628@wbgn013.biozentrum.uni-wuerzburg.de>
URL: https://gitlist.dev/e/Pine.LNX.4.63.0703031720290.22628%40wbgn013.biozentrum.uni-wuerzburg.de
In-Reply-To: <1172925097.11109.25.camel@localhost>

```
Hi,

On Sat, 3 Mar 2007, Raimund Bauer wrote:

> I've just tried it out on my home-box, which is a ubuntu edgy x86 
> installation, and git-cvsimport seems to work quite fine here.
> 
> On our server, which is a suse 9.3 amd64 installation (with the latest 
> suse updates for that version), I just can't get it to run. Currently I 
> wonder how I got _any_ git-cvsimport to work there. Still the same error 
> 256 ...
> 
> How do I find out the minimum-version of tools I need to use
> git-cvsimport? I already know about cvsps and did install a current
> version there, but there seem to be some more dependencies ...
> Or could it be a 64-bit issue somewhere?

It could be. I'd first try cvsps itself, to find out if the issue is not 
there (not many 64-bit issues in Perl, are there?).

Hth,
Dscho

```
