info-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CVS not using environment variables


From: Mark D. Baushke
Subject: Re: CVS not using environment variables
Date: Sun, 13 Jun 2004 21:15:40 -0700

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Jerry Neely <address@hidden> writes:

> I'm trying to access a CVS repository on a
> remote server, but it doesn't appear to be using
> the environment variables I've set. For example:
> 
> $ set | grep CVS
> CVSROOT=:ext:address@hidden:/usr/src/cvsroot
> CVS_RSH=ssh

You need to move it from being a locally set
variable to being one that is a part of your
environment when you fork new commands. The
command:

  export CVSROOT CVS_RSH

should do this for you.

> 
> $ cvs status
> cvs status: No CVSROOT specified!  Please use the `-d' option
> cvs [status aborted]: or set the CVSROOT environment variable.
> 
> Apparently, CVS doesn't see that CVSROOT is set
> in my environment. Though it's not something I'd
> care to have to type all the time, I can get
> around this with the -d option, but this fails
> as well. Using the -t (trace) option shows why:
> 
> $ cvs -t -d :ext:address@hidden:/usr/src/cvsroot status
>  -> main loop with CVSROOT=:ext:address@hidden:/usr/src/cvsroot
>  -> Starting server: rsh cvs.server.com -l my_id cvs server
> cvs.server.com: Connection refused
> cvs [status aborted]: end of file from server (consult above messages if any)
>  -> Lock_Cleanup()
> 
> And I know of no command line options to replace CVS_RSH.

There have been some discussions about how to do
this in a reasonable way.

The CVSNT folks allow a few ways to do it:

    :ext;rsh=remsh:address@hidden:/path/to/repository
    :extssh:address@hidden:/path/to/repository
    :ssh:address@hidden:/path/to/repository
    :ssh;key='c:\id_dsa':address@hidden:/path/to/repository

The CVS project has recently adopted the

   :method;option=arg:

syntax for proxy use as in

    :pserver;proxy=www.myproxy.net;proxyport=8000: 

so, my guess is that rather than providing :ssh:
it will be more likely to provide
:ext:rsh=ssh:address@hidden:/path/to/repository

If anyone wishes to provide patches and tests for
sanity.sh, feel free to provide them.

> Does anyone have any idea why CVS isn't picking
> up the environment variables?

My best guess is that you are not actually putting
them into the environment.

> I'm seeing the exact same behavior on two
> systems. One is running CVS 1.11.2 on Redhat
> 9.0, the other is CVS 1.11.1p1 on Redhat
> 7.1.

If you don't like using a Bourne shell, you could
try tcsh or csh and explicitly use

    setenv CVSROOT :ext:address@hidden:/usr/src/cvsroot
    setenv CVS_RSH ssh

as an alternative...

        Good luck,
        -- Mark
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (FreeBSD)

iD8DBQFAzSZs3x41pRYZE/gRAlkdAJ9Ei6QuTr4HtE2oFOtSNeQiMzFZKgCgpkXi
9dfuuov3NwXP4POatLGxdK4=
=yqdS
-----END PGP SIGNATURE-----




reply via email to

[Prev in Thread] Current Thread [Next in Thread]