[net.unix-wizards] Ucbmail users watch out for Zimmerman"s emacs

thomas (10/25/82)

I recently changed the backup file convention in Gosling's emacs here.
It used to append ".BAK" to the filename (begin semi-smart if the filename
was too long) for backup files and ".CKP" for checkpoint files.  I
decided that I didn't like seeing all those .BAK and .CKP files hanging
around all the time, so I changed it to prepend the strings ".#" and ".~"
(respectively).  Now, we don't even see them when we ls!  (Let's hear it
for . files!)  Note that you don't want to use the character % for this
sort of application, since cron turns all %s into newlines!
=Spencer

z (10/25/82)

Sorry about your problems with the mail help file.  We got around this
problem long ago by including the expression 
	-a ! -name '*.help.~'
in the "find" statement in /usr/lib/crontab.  Unfortunately, when I
wrote up the instructions for the installation of EMACS, I forgot that I
had done this.  This was recently pointed out to me, and at that time I
added a cautionary note to the README file.  You seem to have a version
of EMACS which predates that one.

On the question of backup files in general, tilde actually seems to be a
good choice.  Aside from the mail help file, no other file on Unix uses
it in the trailing position.  It is one of the few special characters
which is neither heavily used nor is a special character to any shell
(at least in the trailing position).  I think that its use by the C
shell to mean "home directory" also causes people to stay away from
casual use of it.

Then there is the question of whether to use a leading or trailing
backup file indicator.  We like the trailing indicator for two main
reasons:  1) Backup files appear next to the files they back up in "ls
-ls" listings, making it easy to compare sizes, dates, etc.  2) You can
see only your primary files by doing something simple like "ls -ls *.c",
or whatever.  If you really want to see both primary and backup, you can
do "ls -ls *.c?".  Prepended backup characters don't seem to be as
flexible.  As for backing up a 14 character file name, EMACS deletes the
last character and replaces it with a tilde.  This is just as good as
prepending a character to a 14 character file name.  Of course, when
4.2BSD arrives with 256 character filenames, this problem will go away.

	Steve Zimmerman
	decvax!cca!z
	z@cca

puder (10/25/82)

Our distribution came with a line in crontab commanding the deletion of all
old files whose names begin with '#', so it appears to be the norm in 4.1bsd.

Gosling's emacs appends '.bak' to the filename, but first truncates the name
to ten characters so the last four characters of the name will really be
'.bak'.  This will presumably not be necessary in 4.2bsd which, I have heard,
will support longer filenames.