1

I use the following code for backup and auto-save files:

(setq delete-old-versions -1)
(setq version-control t)
(setq vc-make-backup-files t)
(setq backup-directory-alist `(("." . "h:/saves")))
(setq auto-save-file-name-transforms '((".*" "~/.auto-save-list/" t)))

The backup files created are all hidden. I would like to change that so that they are made in a non-hidden format.

An example is: !drive_c!home!.emacs.d!recentf.~2~

2

What do you mean by the files being "hidden"? Hidden where, how?

You can specify the file names you want for backup files, if something is causing them to be somehow "hidden" based on their names (use different names). See the Emacs manual, node Backup Names.

And if you're talking about auto-save files, then see node Auto Save Files.

Backup files and auto-save files are not the same thing.


Update after a comment by OP

If this is about Dired hiding files, please specify just what you mean by hiding.

  1. If this is about hiding by omitting, then customize option dired-omit-files. C-h v tells us:

dired-omit-files is a variable defined in dired-x.el.

Its value is "^\\.?#\\|^\\.$\\|^\\.\\.$"

Documentation:

Filenames matching this regexp will not be displayed.

This only has effect when dired-omit-mode is t. See interactive function dired-omit-mode (C-x M-o) and variable dired-omit-extensions. The default is to omit ., .., auto-save files and lock files.

You can customize this variable.

Note that my value of this option includes auto-save files (which end in #).

If this is about Dired showing ignored files differently, then customize option completion-ignored-extensions. C-h v dired-ignored-face tells us:

dired-ignored-face is a variable defined in dired.el.

Its value is dired-ignored

Documentation:

Face name used for files suffixed with completion-ignored-extensions.

And C-h v completion-ignored-extensions tells us this:

completion-ignored-extensions is a variable defined in C source code.

Its value is shown below.

Documentation:

Completion ignores file names ending in any string in this list.

It does not ignore them if all possible completions end in one of these strings or when displaying a list of completions. It ignores directory names if they match any string in this list which ends in a slash.

You can customize this variable.

Value:

(".o" "~" ".bin" ".bak" ".obj" ".map" ".ico" ".pif" ".lnk" ".a" ".ln"
 ".blg" ".bbl" ".dll" ".drv" ".vxd" ".386" ".elc" ".lof" ".glo" ".idx"
 ".lot" ".svn/" ".hg/" ".git/" ".bzr/" "CVS/" "_darcs/" "_MTN/" ".fmt"
 ".tfm" ".class" ".fas" ".lib" ".mem" ".x86f" ".sparcf" ".dfsl" ".pfsl"
 ".d64fsl" ".p64fsl" ".lx64fsl" ".lx32fsl" ".dx64fsl" ".dx32fsl"
 ".fx64fsl" ".fx32fsl" ".sx64fsl" ".sx32fsl" ".wx64fsl" ".wx32fsl"
 ".fasl" ".ufsl" ".fsl" ".dxl" ".lo" ".la" ".gmo" ".mo" ".toc" ".aux"
 ".cp" ".fn" ".ky" ".pg" ".tp" ".vr" ".cps" ".fns" ".kys" ".pgs" ".tps"
 ".vrs" ".pyc" ".pyo")

Your current value is likely different from mine. Notice that mine includes "~", which means that backup files are highlighted as being "ignored" files.

| improve this answer | |
  • I mean that they are treated as hidden files in Dired. – devcom Sep 19 at 17:54
  • Put all such info in the question itself. Comments can be deleted at any time. Questions need to stand on their own. – Drew Sep 19 at 20:26
  • I have customized completion-ignored-extensions by removing ~ and the now files are not longer "hidden". – devcom Sep 20 at 8:19
  • It would probably help others if you clarify what you mean by "hidden" in the question - e.g., describe the visual effect of a "hidden" file. In the case of omission the file is not listed; in the case of being "ignored" it is just highlighted differently. – Drew Sep 20 at 16:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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