Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

My favorite manifestation to date of Emacs file handling is that if I use emacs to edit a post in my Hugo-managed site, and Emacs decides to leave one of its .#filename symlinks around that don't point to anything, hugo gets an error reading the directory and decides the entire directory is busted and doesn't read it in. So suddenly entire years of my blog start disappearing.

Granted, hugo is handling this particularly gracelessly, but it's not the only thing that gets confused and upset by the dangling symlinks that point nowhere.



> Emacs decides to leave one of its .#filename symlinks around that don't point to anything,

Yeah, it breaks other various compilers like ghc too.

I fix it with:

    (use-package no-littering
      :demand t
      :config
      (no-littering-theme-backups)
      )
https://github.com/emacscollective/no-littering


That file is there while there are unsaved changes. Save the file or undo the changes and it goes away.


Avoid committing the # tempfiles or saving them in a separate directory generally solves this problem.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: