How to remember multiple tabs' session in terminal? (Alike FF session manager)

戏子无情 提交于 2019-12-03 05:59:34
ChriS

For the gnome terminal, you can use

gnome-terminal --profile=〈your profile〉 --save-config=〈file〉

I launch it as a background task to save the terminal state periodically.

"termit" can save sessions and is scriptable in lua: https://github.com/nonstop/termit/wiki I don't know about an "undo close tab" feature, though.

For reference, my termit lua config can be found here: https://github.com/thet/dotfiles-termit

On Linux, gnome-terminal is able to load multiple tabs with different working directories. Like termit (which is much more flexible due to it's lua scripting interface), it doesn't have a "undo close tab" feature.

Open Gnome terminal with multiple tabs, each one in another working directory: gnome-terminal --tab --working-directory=/home --tab --working-directory=~ --tab --working-directory=/opt.

Open Gnome terminal with multiple tabs and one base working directory: gnome-terminal --working-directory=/home --tab --tab --tab.

For more options do: gnome-terminal --help-all.

The gnome terminal doesn't have such features, but if you're open to change you could try konsole, it has some nice 'save session' options you could find helpful, though nothing about re-opening accidentally closed tabs, as far as I know.

The other thing, if you're particular about your desktop, is that KDE's konsole might not fit all too well within Gnome.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!