I needed emacs to startup and show me all the files I worked on last time (whom I didn't close explicitly) before M-x kill-emacs. I installed Workgroups for it and my prefix is C-c w. I split the window, ran a few files and I saved a workgroup. After restarting, it showed me all the files I closed last time (first usage). After I worked on some other files, I closed emacs. But the next time I tried to start it, it shows me the files from the first session. My last session wasn't saved and instead my first session files are being shown.

I want to automatically load the files I ran the last time before closing to be arranged just the way it was. How do I fix this?

  • Can you show me your configure? – stardiviner Oct 23 '16 at 10:40

If you use kill-emacs, it will not save the session on exit. You must call save-buffers-kill-terminal or the default exit C-x C-c. So either call save-buffers-kill-emacs or save-buffers-kill-terminal, or add wg-save-session-on-emacs-exit to kill-emacs-hook.

| improve this answer | |
  • It doesn't work. – 2dsharp Oct 27 '16 at 16:18

I guess you forgot to put (workgroups-mode 1) at the bottom of your .emacs. This line code will restore workspaces session.

| improve this answer | |
  • No, I have this enabled. It still doesn't work. – 2dsharp Oct 24 '16 at 5:04
  • Maybe you should do an minimal emacs init content debug? – stardiviner Oct 24 '16 at 5:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.