How can I reload .spacemacs file after editing without restart emacs?

Emacs

Emacs Problem Overview


I am new to emacs(spacemacs), and I follow this article to learn spacemacs.

>Once you are done editing, save the file and either press C-c C-c in the file to reload it or just restart Spacemacs.

But after I save the .spacemacs and then press C-c C-c, the powerline told me C-c C-c is undefined.

How can I reload .spacemacs file after editing without restart emacs?

Emacs Solutions


Solution 1 - Emacs

I found the solution: SPC f e R

It is from "Dotfile Configuration" in the Spacemacs Docs.

Solution 2 - Emacs

SPC f e R doesn't work for me so I personally use SPC q R. It completely restarts spacemacs though - but if you maintain sessions (dotspacemacs-auto-resume-layouts t) in config), spacemacs will restart with same buffers. Hope it'll help someone.

dotspacemacs-auto-resume-layouts is a config option which can be found in setq-default section of your .spacemacs file. It comes with default spacemacs setup, it's default value is nil.

Solution 3 - Emacs

For those who work in emacs mode, it might be little difficult to get this done with keybindings. In such case, do M-X then type dotspacemacs/sync-configuration-layers

Solution 4 - Emacs

SPC q r or (restart-emacs-resume-layouts) will restart emacs whilst preserving the layout.

Solution 5 - Emacs

Another way to do this is press space twice (SPC SPC) which brings you into the emacs command mode.

Then type: sync-config and press Enter which will execute the dotspacemacs/sync-configuration-layers command and reload your config.

Categories

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
Questionuser2331095View Question on Stackoverflow
Solution 1 - Emacsuser2331095View Answer on Stackoverflow
Solution 2 - EmacsvalignatevView Answer on Stackoverflow
Solution 3 - EmacsVeeraView Answer on Stackoverflow
Solution 4 - EmacsSherlockView Answer on Stackoverflow
Solution 5 - EmacsmpaepperView Answer on Stackoverflow