help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: permissions on created files


From: Tim X
Subject: Re: permissions on created files
Date: Tue, 19 Sep 2006 13:11:08 +1000
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux)

Urs Thuermann <urs@isnogud.escape.de> writes:

> When emacs creates a new file, it does so using mode 0666 modified by
> the process umask, i.e. newly created files don't have the executable
> bit set.  I have search the Emacs docs (with C-h i) and have also
> tried C-h a to find a way to change this.  I'd like to change emacs'
> behavior so that it uses 0777 instead 0666 when the file begins with
> the two characters #!.  Is that possible?  I couldn't find anything
> like that.
>
>
> urs

I think emacs just inherits the default umask from your environment.
However, thre are some variables which can control the setting of
executable bits on script files created within emacs. I'm not sure
what version of emacs you are running, but a quick apropos in emacs 22
brings up the function

executable-make-buffer-file-executable-if-script-p

which sounds promising as a starting point. 

Tim



-- 
tcross (at) rapttech dot com dot au


reply via email to

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