Table of Contents
emacs 25
/usr/bin/emacs --version GNU Emacs 25.2.2
Step1: plain emacs
Remove all emacs config file/folder
rm -rf ~/.emacs.d ~/.emacs emacs
Step2: Download gnu-elpa-keyring-update-2019.3.tar
gnu-elpa-keyring-update-2019.3.tar https://elpa.gnu.org/packages/gnu-elpa-keyring-update.html
emacs
Run
M-x package-install-file on the tarfile.
Then you will see ~/.emacs is generated
;; Added by Package.el. This must come before configurations of ;; installed packages. Don't delete this line. If you don't want it, ;; just comment it out by adding a semicolon to the start of the line. ;; You may delete these explanatory comments. (package-initialize) (custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(package-selected-packages (quote (gnu-elpa-keyring-update)))) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. )
Copy paste custom-set-variables part to your init.el
(custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. '(package-selected-packages (quote (gnu-elpa-keyring-update)))) (custom-set-faces ;; custom-set-faces was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. )
Next,
rm ~/.emacs Set up your .emacs.d/init.el emacs
DONE!
Reference
gnu-elpa-keyring-update
https://elpa.gnu.org/packages/gnu-elpa-keyring-update.html
emacs gpg key issues
https://www.reddit.com/r/emacs/comments/ddjo76/emacs_gpg_key_issues/
Dealing with Expired ELPA GPG Keys
https://metaredux.com/posts/2019/12/09/dealing-with-expired-elpa-gpg-keys.html
error: Package ‘undo-tree-’ is unavailable #1225
spacemacs emacs26.3
https://github.com/syl20bnr/spacemacs
Launch Emacs. Spacemacs will automatically install the packages it requires. There is a well-known issue with some GPG keys having expired end of 2019. This can be fixed by upgrading to Emacs 26.3 or above or by manually adding the new keys using something like: gpg --homedir ~/.emacs.d/elpa/gnupg --receive-keys 066DAFCB81E42C40 If you have a restrictive firewall it may help to manually specify the keyserver: gpg --keyserver keyserver.ubuntu.com --homedir ~/.emacs.d/elpa/gnupg/ --receive-keys 066DAFCB81E42C40
Run Alt x: ESC x
If your Emacs does not recognize your Alt key as the Meta key, you can type ESC x instead of M-x .
ESC x does not work under evil mode.