Using Emacs with ido mode enabled on Windows, Emacs tries to save a history file .ido.last when exiting. The file is located in C:/.ido.last, but it fails with a permission denied message. This is strange since I actually have access to that folder. However:
Is there a command to change the directory where the .ido.last file gets saved?
Short answer:
(setq ido-save-directory-list-file "/some/file/name").Long answer:
I keep all the little files that remember Emacs's state in a single directory under the
user-emacs-directory. I'm not sure what this is on Windows, but I think it'sC:\Users\<username>\Application Data\.emacs.d\. On Unix, it's~/.emacs.d/. The variableuser-emacs-directoryshould be defined by Emacs, no need to set it.You may want to look at the
no-litteringpackage, which sets better default locations for files like this.