Path: utzoo!utgpu!water!watmath!clyde!bellcore!faline!ulysses!allegra!princeton!udel!rochester!cornell!batcomputer!pyramid!prls!mips!hansen From: hansen@mips.UUCP Newsgroups: comp.emacs Subject: Re: Emacs kills hard links! Message-ID: <1343@mips.UUCP> Date: 16 Jan 88 07:15:30 GMT References: <280@expya.UUCP> <400@sol.warwick.ac.uk> Lines: 28 Posted: Sat Jan 16 02:15:30 1988 In article <400@sol.warwick.ac.uk>, maujf@daisy.warwick.ac.uk (Mike Taylor) writes: > ...since I changed to emacs, I have been stunned to find that when > overwriting a linked file, emacs destroys the links, leaving me with only > one version of the file changed. > > I guess those of you who have been using Emacs since the dawn of time will > have heard all this many times before, but could anyone tell me a neat and > simple way around this? Maybe something I can put in my .emacs file so > that it maintains links with edited files? Put the following in your .emacs to cause hard links to be retained: (setq backup-by-copying-when-linked t) The following line will also keep the file modes and ownership retained: (setq backup-bn-copying-when-mismatch t) Now, can anyone tell me how to get emacs to understand that if /user/hansen is a symbolic link to /n/electron/vlsi/hansen, that /user/hansen/.emacs is the same as /n/electron/vlsi/hansen/.emacs, so it won't open two separate buffers for the same file??? [This occurs if, while starting with /user/hansen as your current directory, you enter "emacs .emacs" and then later do a find-file on "/user/hansen/.emacs"] -- Craig Hansen Manager, Architecture Development MIPS Computer Systems, Inc. ...{ames,decwrl,prls}!mips!hansen or hansen@mips.com