Update Spacemacs from command line


Ever since I’ve started using Spacemacs on Linux, I’ve been using this simple script as a command alias to update Spacemacs using the command line.

alias upe='git -C ~/.emacs.d/ pull && \
  emacs --batch -l ~/.emacs.d/init.el \
  --eval="(configuration-layer/update-packages t)" 2>&1 | \
  tee /tmp/emacs-update && \
  grep -i -E "Found.*to.*update.*" /tmp/emacs-update && \

I use the develop branch of Spacemacs, thus the update using git. Then it will check if there are package updates and if so, it will relaunch Spacemacs to actually install the updates.

If you have any questions or feedback, please reach out @flowerinthenyt.

Creative Commons License
This work is licensed under a Creative Commons Attribution 4.0 International License.