Re: file permissions
Re: file permissions
- Subject: Re: file permissions
- From: Jonathan Rochkind <email@hidden>
- Date: Tue, 18 Mar 2003 10:29:12 -0600
When I looked into this, it didn't look like there was any way in the Java
API to change the file permissions of an individual file. Or maybe I just
didn't find it.
But if you want ALL files to be rw-rw-rw- instead of rw-r----, you could
set the umask for your java process. You could edit the launch script for
your app (or the launch script for WOTaskd if you want it to apply to all
apps, or is that just all apps launched by Monitor? Not sure) to use the
unix 'umask' command before actually launching the app. See the man page
for umask.
Of course, the app launch script will get rewritten on every compile. I'm
not sure how you'd really integrate this umask thing into your build cycle.
(There should also put umask in your own .profile, or whatever OSX might
use to do the same thing, to set the umask for processes launched from an
interactive shell) But anyway setting the umask to provide the mask for
ALL files created by your Java process is the only way I've found to effect
the permissions of created files.
--Jonathan
At 01:23 PM 3/18/2003 +0100, you wrote:
hello,
how can i set the file permissions of a file created in java like this?
rw-rw-rw-
if i create a file the permissions are always like this
rw-r--r--
thanks,
juergen
_______________________________________________
WebObjects-dev mailing list
email@hidden
http://www.omnigroup.com/mailman/listinfo/webobjects-dev
_______________________________________________
webobjects-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/webobjects-dev
Do not post admin requests to the list. They will be ignored.