I currently have Emacs encrypting a .gpg file transparently as is the expected behaviour and I'm wondering if this can be extended to all file types so that Emacs can attempt decryption on all files without having to use the .gpg extension. I know something like this can be done with org-mode and txt files:
(add-to-list 'auto-mode-alist '("\\.txt$" . org-mode))
But is there an equivalent for gpg too?
To clarify, I don't mean having to call a file foo.org.gpg to open it in org-mode, rather just foo.org and still encrypt/decrypt it anyway without needing ;; -*- epa-file-encrypt-to: ("[email protected]") -*-
either.
*.org
file which is not encrypted?*.org
or*.md
or*.txt
or*.tex
(which is pretty much all the types I have), are not encrypted, but for those that are, I want to continue using the "proper" extension and still have Emacs check before opening and, if they're not encrypted, do nothing else but open them.