When an Emacs buffer is modified, a broken link is created. The link's name is a concatenation of '.#' followed by the file's name. For example:

$ ls .#spacemacs_ref.org -l
lrwxrwxrwx. 1 wolfv wolfv 44 Aug 18 01:11 .#spacemacs_ref.org -> wolfv@localhost.localdomain.17997:1502966690

The '.#' link goes away when the file is manually saved, but not when auto-saved. Auto-save happens in 30 seconds and the mode-line's '*' changes to '-'. If I manually save the file after auto-save occurs, the mini-buffer says "(No changes need to be saved)". Which is true, but the '.#' link remains.

In my .spacemacs configuration file sets auto-save to original file:

(defun dotspacemacs/init ()
 dotspacemacs-auto-save-file-location 'original

What is the purpose of the '.#' links?

I am using Emacs 25.2.1 with Evil Spacemacs and Ivy on Linux.


Symbolic links of the form “.#*” are not auto-save files, their purpose is to prevent the simultaneous editing of the same file. See Interlocking and File Locks in the Emacs Manual.

| improve this answer | |

Not the answer you're looking for? Browse other questions tagged or ask your own question.