[Top][All Lists]

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

Re: $CVS_USER won't expand in loginfo...

From: Larry Jones
Subject: Re: $CVS_USER won't expand in loginfo...
Date: Tue, 3 Sep 2002 16:05:23 -0400 (EDT)

Rudman, Chris writes:
> I'm using CVS v1.11 and i just can't seem to get the $CVS_USER environment
> variable expanding in any of my *info files.

Environment variables aren't expanded in *info files (although they are
usually expanded in scripts called from *info file).

> I can get $USER to expand, but this of course
> expands into 'cvsowner' as the server user, and not the actual CVS user who
> performed the commit. I've tried all sotrs of forms ($CVS_USER,
> $CVS_USERNAME, %CVS_USER_NAME, ${CVS_USER}, etc etc), and i always get the
> same error reported back:"cvs server: loginfo:27: no such internal variable

Perhaps you should try looking up "internal variable" in the fine


> In my loginfo file i only have a single line:-
> ^cgr_test /export/cvs/CVSROOT/loginfo.ksh $CVS_USER %{sVv}

The internal variable you want is $USER (not to be confused with the
environment variable of the same name which, as you note, contains the
wrong user).  That will set the first argument in your script ($1 for
ksh) to the CVS user name; it will not set any environment variables. 
Newer versions of CVS set the $CVS_USER environment variable to the
value of the $USER internal variable, but I don't remember whether 1.11
is new enough to do that or not.

-Larry Jones

Is it too much to ask for an occasional token gesture of appreciation?!
-- Calvin

reply via email to

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