Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

emacs: how to disable .# files creation [duplicate]

Tags:

emacs

elisp

Possible Duplicate:
Why does emacs create temporary symbolic links for modified files?

Every time I edit file emacs creates file similar to:

lrwxrwxrwx  1 vladimir vladimir   49 2011-11-23 19:20 .#models.py -> [email protected]:1322037576

I already tried

(setq auto-save-default nil)

but without success. How can I disable such behavior?

like image 201
Vladimir Mihailenco Avatar asked Nov 23 '11 17:11

Vladimir Mihailenco


People also ask

How do I stop a command in Emacs?

To quit Emacs permanently, type C-x C-c.


1 Answers

As of emacs 24.3 it is possible to disable lock files using the the "create-lockfiles" option int the Emacs customization system or by directly setting the create-lockfiles variable to nil:

(setq create-lockfiles nil) 

In previous Emacs versions there's no way to disable this functionality through a customization. You could hack the C code to prevent the links from showing up. But that's probably more work than you want.

The links are there to serve as file locks, to enable Emacs to recognize when someone else is already editing the file. See the documentation here and here.

like image 114
Trey Jackson Avatar answered Sep 24 '22 13:09

Trey Jackson