所以任何shell/终端缓冲区都会在会话之间变成文本或刮擦(如果我再次关闭并打开spacemacs(
我正在做 TDD,让摩卡在工作区一侧的 vsplit 窗口中运行测试非常方便。
最好的方法是什么?
谢谢
你是对的。 当您关闭 emacs 时*shell*
缓冲区将恢复为*scratch*
。(在这种情况下,我猜您使用 desktop.el 来实现持久会话(
不幸的是,dekstop.el不支持保存*shell*
缓冲区。因此,当您尝试保存它时,它将恢复为*scratch*
。
好消息是您可以使用桌面+来满足自己的需求。 引用文档
默认情况下,桌面会话仅保存与"真实"文件关联的缓冲区。Desktop+>通过处理"特殊缓冲区"来扩展这一点。当前支持的 s 列表 特殊缓冲区类型为:
- compilation buffers (in `compilation-mode`) - terminal buffers (in `term-mode`) - org agenda & todo lists (in `org-agenda-mode`) - indirect buffers (a.k.a clones). - man pages (in `Man-mode`) - shell buffers (in `shell-mode`)
PS:我不使用spacemacs。根据您的解释,我认为spacemacs默认激活desktop.el