cvs via Cygwin (W98) to FAT to Linux - permissions
Randall R Schulz
rrschulz@cris.com
Wed Jun 27 20:38:00 GMT 2001
Steve,
OK. Moving on from a shoot-from-the-hip suggestion, I checked out the CVS
manual (and old one, admittedly--version 1.9).
According to section 4.2.2, pg. 16, files in the working copy of the
repository have permissions "typical for newly created files, except that
sometimes CVS creates them read-only."
I take this to mean that the CVS command creates the files with mode 0666
(or 0444 in the read-only case) and that the prevailing umask value is used
to pare them down from there.
Thus, it seems you really have very little to do, in fact. The files are
either (0666& ~umask) or (0444 & ~umask).
For a FAT file system volume, then, the only distinction is whether or not
the read-only attribute is set.
I don't know the details, but probably cygwin1.dll already handles this?
Randall
At 20:11 2001-06-27, Steve Jorgensen wrote:
>Sounds good, but I'm confused.
>
>How can the script see the file permissions before they're received, and
>where can it get the file permission information from after they're
>received and saved without the information?
>
>-----Original Message-----
>From: Randall R Schulz [SMTP:rrschulz@cris.com]
>Sent: Wednesday, June 27, 2001 8:05 PM
>To: jorgens@coho.net; Cygwin List (E-mail)
>Subject: RE: cvs via Cygwin (W98) to FAT to Linux - permissions
>
>Steve,
>
>There's nothing wrong with wanting this outcome, but modifying the CVS
>command itself is almost certainly not the way to get it.
>
>Much better would be to wrap CVS in a script that would perform the
>necessary actions required to achieve this effect. As a shell script, this
>wouldn't be particularly tough.
>
>In fact, it reminds me of a program I wrote once, you gave it a list of
>file names and a command to invoke. It saved the modify and read times of
>the named files, ran the command and after it exited, restored the mod and
>read times on the files. Although that was a C program, if I was writing it
>today, I'd probably do it in BASH.
>
>Be sure to take care with signal handling.
>
>Randall Schulz
>Mountain View, CA USA
>
>
>At 19:34 2001-06-27, Steve Jorgensen wrote:
> >...
> >
> >That brings me back to the more limited, but vastly simpler idea of adding
> >a feature to cvs that allows producing a script of chmod commands during
> >check-out that reflects the proper file permissions. I might even attempt
> >this myself after re-learning such things as how a make file works since I
> >haven't done C programming in about 12 years now.
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
More information about the Cygwin
mailing list