7 ms·
Not related to the speed, but is there any terminal for Linux that works like the Mac OSX terminal, in that you can shut it down and restart and it will bring u
by l33tman 3y ago
Not related to the speed, but is there any terminal for Linux that works like the Mac OSX terminal, in that you can shut it down and restart and it will bring up all the tabs and their cmd histories and scrollbacks for each tab? They do that by setting different bash history files for each tab etc.
And I prefer GUI terminals for this use-case...
- pxc 3y ago> And I prefer GUI terminals for this use-case... This probably isn't to your liking, then, but perhaps it will be of use to someone else: https://github.com/tmux-plugins/tmux-resurrect https://github.com/tmux-plugins/tmux-resurrect (You can, of course, use tmux with any GUI terminal emulator you like.)
- johnchristopher 3y agoI suppose you could "just" run tmux and have more or less the same results (opened tabs with history, but won't survive a reboot) ?
- cqqxo4zV46cp 3y agoA lot leaning on “more or less”.
- Brian_K_White 3y agoA lot depends on what are the important parts. It could be essentially identical if it supplies all the parts you care about and don't actually care too much what exact form it takes. But if you require the same exact gui controls then sure, totally different and not even an answer to the question.
- johnchristopher 3y agoYeah, it's not the same experience. And you have to get into tmux configs which is a hassle by itself. I am not a fan of terminal multiplexers, I tend to forget them and when the server crashes or reboot it won't replay/restart what I was doing in those tabs anyway. I just use them for long running jobs I am testing. I also don't like the whole tmux window/pane manipulation you can do, I'd rather have my primary DM to do that well. It's funny how tmux is downvoted in those replies though :D.
- deleted 3y ago[deleted]
- okasaki 3y agoYou don't have to get into tmux configs. It's perfectly usable out of the box.
- johnchristopher 3y ago(Here we go...)
- lupusreal 3y agoI'm curious what your essential configurations are. I've been using default tmux for years, am I missing out?
- lanstin 3y agoI remap the escape key away from C-a as that conflicts with emacs and I increase the scrollback size of sessions.
- opan 3y agoIt's C-b by default, C-a is what screen uses. Maybe you copied someone's config, as that remapping is fairly common (or weird distro default? but seems unlikely). I'm personally fine with the default C-b and have always kept it everywhere.
- 3np 3y agoPersonally the only thing I really need is `mode-keys vi`, the rest is optional. I guess you want to configure mouse on/off depending on preference, if it differs from the default. Usually will at least change the color of workstations and desktops just to make it more visually obvious which tmux environment I'm looking at when sshing and nesting.
- 3y ago
- apienx 3y agoI use Tmux. It's a terminal-agnostic multiplexer. Gives you persistence and automation superpowers. https://github.com/tmux/tmux/wiki https://github.com/tmux/tmux/wiki
- severino 3y ago> They do that by setting different bash history files for each tab etc. I wonder what happens when you close all the tabs, and then open a new one. Are all the tabs history merged back into a "general" history file when you close them, so you will get access to its commands in new ones?
- livrem 3y agoI set HISTFILE=~/.bash_history_$TMUX_PANE (when that variable is set). A bit kludgy, but works good enough for me.
- severino 3y agoYes, but if one process is writing its history to ~/.bash_history_1, and some time later you spawn a new shell whose history file points to ~/.bash_history_2, you won't have the commands from the previous session available, right?
- livrem 3y agoCorrect, but most of the time I use the same set of panes, created at startup, so the commands are in the history where I need them. And when they are not I grep in ~/.bash_history_*.
- __jonas 3y agoThis is pretty tangential, but I just (1 hour ago) found out that iterm2 on Mac can integrate with tmux [1] if you run tmux with the argument "-CC", in a way that makes your tmux sessions map to the GUI windows / tabs in iterm2, including when using tmux on a remote machine via ssh. I'm really excited about this, since I always forgot the hotkeys/commands for controlling tmux. [1] https://iterm2.com/documentation-tmux-integration.html https://iterm2.com/documentation-tmux-integration.html
- felixding 3y agoAFAIK, iTerm2 is still the only terminal that support this tmux control mode.
- jesprenj 3y agoVSCode/vscodium's IDE terminal does this.
- dacryn 3y agono it doesn't, at least not in my case. Any settings to do?
- spockz 3y agoIt does for me when using a remote instance, like a devcontainer or over ssh. Maybe that is just because the server side keeps running and when you reconnect the UI reloads from there. Locally nothing would remain to be reloaded when you restart VSCode.
- slaughtr 3y agoPresuming my understanding of persistent sessions lines up with yours, set `terminal.integrated.enablePersistentSettings`. You may also want to change the value of `terminal.integrated.persistentSessionScrollback` to something higher than the default (1000? not sure)
- progmetaldev 3y agoIs that not related to Powershell's handling of history?
- Medox 3y agoTabby [1][2] has "Restore terminal tabs on app start" under Settings > Terminal > Startup. [1] https://tabby.sh/ https://tabby.sh/ [2] https://github.com/eugeny/tabby https://github.com/eugeny/tabby
- Asmod4n 3y agoAt the time mac os got that functionality their macbooks had removeable batteries. One fun fact: you could just remove the battery while your apps where running and when booting up again every window you had open would just reopen with everything you had typed saved to disk in case of the iwork apps.
- progmetaldev 3y agoWhile I fully believe this could work, seems like it might need to be a temp solution. Ripping out the battery seems like a solution that might have more downsides than advantages.
- deleted 3y ago[deleted]
- robert_foss 3y agoguake
- freedomben 3y agoindeed, if you just need a quick terminal for the odd command here and there, guake is amazing
- jmholla 3y agoI am on the command line almost all the time and use guale almost exclusively. Basically it and Firefox. I love my setup.
- miohtama 3y agoWarp? https://www.warp.dev/ https://www.warp.dev/ Might not be 1:1 what you ask for, but it can do scrollbacks for sure and has very advanced command history features.
- mplanchard 3y agoI have heard some good things about this, but I refuse to use a closed source terminal.
- deleted 3y ago[deleted]
- gaws 3y agoYou even need an account to use it. Pass.
- DanielVZ 3y agowarp.dev is a good alternative
- gaws 3y ago> good alternative - Closed source - Requires an account to use - Collects your data No, thanks. There are plenty of superior options out there.
- prmoustache 3y agoI find it more preferable to setup bash (or whatever shell you are using) to append into .BASH_HISTORY file at every command. You don't always remember on which tab/pane/window you type which command and most people would do Ctrl + R or use a fuzzy search tool anyway. Also many times you open a new tab/pane/window and would like to access the history of another one who is already busy running a job so a common history is usually preferrable. YMMV of course.
- prmoustache 3y agoYou can do the saving part automatically by setting a different history file automatically for each instance of the shell, for example using a timestamp on your rc file and force them to append after every command. Then if you open a new shell and want history from a particular older shell you can do `history -r <filename>` So it is an hybrid automatically saved, manually recovered mode.
- fikama 3y agoThis. I was just looking for the exactly the same thing. For now I use tmux with tmux-ressurect to persist state between reboots. - It works okeyish, I would say it's a good hack but still a hack. It's sad there isn't really solution for this problem maybe aside for warp. My little UX dream is to have such a solution of saveing workspaces integrated with whole OS and apps inside it. - That would be cool.
- yjftsjthsd-h 3y agoYou could do that with VMs. Maybe qubes?