Hacker News new | ask | show | jobs
by syl20bnr 3573 days ago
There is such support in Spacemacs, it is called "spacemacs layouts" but the tab is visible only on demand while pressing `SPC l`. Eyebrowse is also integrated in Spacemacs layouts so you can have multiple sub-layouts for a given layouts. Note that Spacemacs layouts also achieve buffer isolation so you can have a layout restricted to project's buffers only, you can also create your own rules to automatically add buffers to some layouts (called custom layouts). Last you can persist Spacemacs layouts across sessions.
2 comments

Layouts are fucking great. I have a moderately complex layout set up for my org-mode workflow (tasks list top left, agenda top center, notes file top right, kanban board bottom-left, and a scratch buffer bottom right), and they all load the same way every time. And I have project-specific layouts that get auto-loaded when I open that projectile project, and I have a general programming one as well. All of these took less than an hour to set up and work completely flawlessly.
I haven't used layouts much, but that sounds very useful.

Do you have your dotfiles somewhere online? Or could you put up the code needed for that setup in a gist/pastebin?

I don't have the dotfile up anywhere, but I can run you through the basics really quickly:

* SPC-l gives you the layouts micro-state, which allows you to do all of this. First, set up your layout however you'd like, then open up the micro-state and run the save-as command (SPC-l-S) and that will allow you to save the layout to a layouts file somewhere deep in the bowels of Spacemacs.

* When you're ready to use your layout, use SPC-l-L to load the layout from a file. Type its name (Helm is used, so you get narrowing/fuzzy-find for free) and the layout will load. Note that if you already had another layout loaded, it will load it to the next workspace (accessible through SPC-l-<workspace-number>).

* As for the org Kanban board, check here: http://www.draketo.de/light/english/free-software/el-kanban-... To add this to spacemacs, just open your .spacemacs file (SPC-f-e-d) and add `kanban` to your `dotspacemacs-additional-packages` list.

Spacemacs layouts are like having clippy in your text editor. "It looks like you're opening a tab, would you like to continue?", "What would you like to name this tab?". Vim just opens a tab.