[Top][All Lists]

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

root encounters a readonly file

From: Dan Jacobson
Subject: root encounters a readonly file
Date: 30 Mar 2001 04:38:06 +0800
User-agent: Gnus/5.0808 (Gnus v5.8.8) Emacs/20.7

Maybe emacs should have a variable that doesn't make root's behaviour
a special case when dealing with "readonly" files,
-r--r--r--    1 root     root         1029 Dec 29 04:33 some_file

Emacs treats this as a -rw--... file.

True, in Info it says:
If you visit a file that the operating system won't let you modify,
Emacs makes the buffer read-only, so that you won't go ahead and make
changes that you'll have trouble saving afterward.  You can make the
buffer writable with `C-x C-q' (`vc-toggle-read-only').  *Note Misc

vi [vim]: warns upon opening, and won't let root write this file
        without big hassle [w!]
pico: treats like -rw-...
ed: treats like -rw-...

Actually if one follows my idea and starts warning root, then it
should warn root upon editing non root owned files, which pretty soon
takes the fun out of being root.  Therefore I think I got it wrong.
Therefore all I now propose is a line added to the above
"For the superuser, all permission  and ownership restrictions are ignored,
as is consistent with the operating system."
http://www.geocities.com/jidanni Tel886-4-25854780 e-mail:restore .com.

reply via email to

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