Switching projects in emacs

I would like to associate a lot of buffers / files in emacs with different projects and switch from one to another. This includes closing all buffers associated with this project, and opening files that correspond to the switched project. I tried setting up the desktops using + bookmarks, as suggested at https://emacs.stackexchange.com/questions/315/using-desktop-for-basic-project-management , but all buffers remain open. I also tried setting up workgroups using workgroups2 ( https://github.com/pashinin/workgroups2 ), but had similar problems. Is there an existing emacs package that could be used for this?

+4
source share
3 answers

There is a great package called Projectile that does exactly what you describe and more.

+4
source

Alternative offer

I recommend that you do not look for emacs to manage the buffers, frames, and editor state separately for projects.

. , emacs ( , ), - , , .

+2

: " +, using-desktop-for-basic-project-management, .".

, , , . . , ?

, , .

, , - , . , , (, desktop-buffer-mode-handlers).

+ , . , , (1) , , , (2) .

desktop-after-read-hook desktop-buffer-mode-handlers, .

(But it doesn't seem like you really thought out what kind of behavior you want for buffers that you don't want to “stay open” so you can clearly indicate it. If you can specify it, you can probably implement it quite easily, using either desktop hooks, or bookmarks, or both, just guess.)

+2
source

Source: https://habr.com/ru/post/1568689/


All Articles