I'm working on a shell script to automate the way I install linux on my computers. I'd like to incorporate some emacs customizations into this script.
For example, as soon as emacs is installed, I'd like the following set:
- The init file should be in
tool-bar-modeshould both be set to
version-controlshould be set to
kept-old-versionsshould both be set to
'(("." , "~/.cache/emacs-saves"))
Is there a way to automate this from a shell script?
I suppose that one way to do it would be to simply write these settings to the init file with something like
#!/bin/sh mkdir -p ~/.config/emacs cat > ~/.config/emacs/init.el <<EOF '(menu-bar-mode nil) '(tool-bar-mode nil) '(kept-new-versions 5) '(kept-old-versions 5) '(backup-bycopying t) '(delete-old-versions t) '(global-linum-mode t) '(line-number-mode t) '(version-control t) '(backup-directory-alist '(("." . "~/.cache/emacs-saves"))) EOF