Re: .cvsrc files

2002-04-09 Thread Joi Ellis

On Tue, 9 Apr 2002, Jason Frisvold wrote:

> Is there a way to enable a user to commit files to a repository without
> a .cvsrc file?  I have a script that I use to commit router backup files
> to a cvs repository.  I want to be able to run this via a "fake" user..
> The user has no home directory, nor does it have a shell.  So, I need to
> specify everything as a command line...
> 
> The errors I'm getting when trying to do this are :
> 
> cvs [checkout aborted]: can't chdir(/home/script): No such file or
> directory
> 
> cvs add: /tmp/Routers/10.7.0.1.config added independently by second
> party
> cvs commit: Up-to-date check failed for `/tmp/Routers/10.7.0.1.config'
> cvs [commit aborted]: correct above errors first!
> 
> 
> Any ideas on how to fix this?
> 

Here's a section of a perl script I wrote that allows user nobody to
perform checkouts to /tmp.

sub _cvsLogin {
  my $target = shift;
  my $workDir = $target->workdir();
  my $repository= $target->repository();
  my $cmd = "export CVS_PASSFILE=$workDir/.cvspass; cvs -d $repository login";
  my @input = ( $target->userpw() );
  my ($i,$j) = &logTick( $cmd, $target->buildlog(), \@input, 0);
}

Basically I'm telling cvs to put the .cvspass file in /tmp instead of ~,
since user nobody as a ~ default of / and no rights to use it.

  export CVS_PASSFILE=/tmp/.cvspass

I am able to do cvs login, checkout, update, and tag without a .cvsrc file.
I haven't tried to code up a commit routine, but if tag will work, I think
commit will also.  (My code is tested with repositories that use pserver and
local access.)

-- 
Joi EllisSoftware Engineer
Aravox Technologies  [EMAIL PROTECTED], [EMAIL PROTECTED]

No matter what we think of Linux versus FreeBSD, etc., the one thing I
really like about Linux is that it has Microsoft worried.  Anything
that kicks a monopoly in the pants has got to be good for something.
   - Chris Johnson


___
Info-cvs mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/info-cvs



.cvsrc files

2002-04-09 Thread Jason Frisvold
Title: .cvsrc files






Is there a way to enable a user to commit files to a repository without a .cvsrc file?  I have a script that I use to commit router backup files to a cvs repository.  I want to be able to run this via a “fake” user..  The user has no home directory, nor does it have a shell.  So, I need to specify everything as a command line…

The errors I’m getting when trying to do this are :

cvs [checkout aborted]: can't chdir(/home/script): No such file or directory

cvs add: /tmp/Routers/10.7.0.1.config added independently by second party

cvs commit: Up-to-date check failed for `/tmp/Routers/10.7.0.1.config'

cvs [commit aborted]: correct above errors first!


Any ideas on how to fix this?

Thanks,

---

Jason H. Frisvold

Senior ATM Engineer

Engineering Dept.

Penteledata

CCNA Certified - CSCO10151622

[EMAIL PROTECTED]

---

"I love deadlines.  I especially like the whooshing sound they make as they go flying by." -- Douglas Adams [1952-2001]