A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
The Software Craftsman
this week in the
Linux / UNIX
UNIXhow to ensure files created in a directory automatically has group "w" permission
Joined: Jun 30, 2006
Feb 28, 2007 16:34:00
I have current directory permission setting
drwxrwxr-x abc abc mydir
if I "cd mydir", and create a new file "myfile", I saw following permission setting for "myfile"
-rw-r--r-- abc abc myfile
How can I make it be like
-rw-rw-r-- abc abc myfile
Note: I am referring to any new file, not existing files. For existing files, I know I can simple do "chmod g+w *" inside the directory. thanks for help in advance !
Joined: Jun 02, 2003
Mar 01, 2007 19:39:00
I don't know how to change this for every file created in a directory, but you may use
umsask 112 touch foo touch bar # ... umask 022
- at least my linux behaves this way.
man bash /umask
was my only information source.
Have you tried LearnNowOnline?
subject: UNIXhow to ensure files created in a directory automatically has group "w" permission
How Do I Use FilenameFilter?
What''s going on with file names??
File class questoin
question about "ls -l" resultd
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015