Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
* emacs and hard links
@ 2000-11-11  1:09 Zufar Mulyukov
  2001-02-20 16:41 ` Ross A Knepper
  0 siblings, 1 reply; 4+ messages in thread
From: Zufar Mulyukov @ 2000-11-11  1:09 UTC (permalink / raw)
  To: axp-list@redhat.com

Hello,
   I have found out that on my RedHat 6.2 (Alpha) emacs works strangely
with hard links.
When editing a hard link to a file ( or a file with some hard link to
it),
a file is saved under different inode, thus creating two different
files. No such problem with vi. Is it supposed to be this way? 
Thank you,
Zufar





^ permalink raw reply	[flat|nested] 4+ messages in thread
* Re: emacs and hard links
@ 2001-02-26 20:13 William H. Magill
  0 siblings, 0 replies; 4+ messages in thread
From: William H. Magill @ 2001-02-26 20:13 UTC (permalink / raw)
  To: axp-list

>   From: Ross A Knepper <rak@zk3.dec.com>
>   Date: Tue, 20 Feb 2001 11:41:15 -0500 (EST)
>
>   this is normal emacs behavior.  it really has nothing to do with
>   alpha.   i believe that it renames the old file to file~ and then creates
>   a new file with the old name.  if you don't like it, use vi ;)
>
>    -ross
>
>   On Fri, 10 Nov 2000, Zufar Mulyukov wrote:
>   >    I have found out that on my RedHat 6.2 (Alpha) emacs works strangely
>   > with hard links.
>   > When editing a hard link to a file ( or a file with some hard link to
>   > it),
>   > a file is saved under different inode, thus creating two different
>   > files. No such problem with vi. Is it supposed to be this way? 
>   > Thank you,
>   > Zufar
>
Yes, this is normal emacs behavior. Emacs uses the mv command first and
then creates the new file. This does change ownership, and protections
as well as kill off links.

To change it, in your ".emacs" file add:

        (setq backup-by-copying 1)

or eliminate the creation of <filename>~ backup files add:
        (set make-backup-files nil)

Note that in Tru64 5.1 (maybe even in 5.0A, I forget) this default behavior
of emacs was changed to deal with the Context Dependent Symbolic Links
(CDSL) found in TruCluster 5.1. They also switched from using GNU emacs
to using Xemacs.

-- 
                        www.tru64unix.compaq.com
                              www.tru64.org
                             comp.unix.tru64
                        
T.T.F.N.
William H. Magill                          Senior Systems Administrator
Information Services and Computing (ISC)   University of Pennsylvania
Internet: magill@isc.upenn.edu             magill@acm.org
http://www.isc-net.upenn.edu/~magill/




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2001-02-26 20:13 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-11-11  1:09 emacs and hard links Zufar Mulyukov
2001-02-20 16:41 ` Ross A Knepper
2001-02-20 19:47   ` Zufar Mulyukov
  -- strict thread matches above, loose matches on Subject: below --
2001-02-26 20:13 William H. Magill

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox