Hacker News new | ask | show | jobs
by plett 318 days ago
I view "you might not need tmux" in the same way as "you might not need browser tabs".

Yes, if you only have one or two terminal sessions or open web pages then you can probably live without using them, but anything beyond that leads you into reimplementing features to cope with your desktop's lack of ability to manage dozens of windows.

6 comments

That is something I have strived for recently, to use all the great window management features of my window manager of choice instead of browser tabs or lots of terminal tabs running tmux. If that didn't work well I guess it would have been a good sign that I need a better window manager. Even went back to use bookmarks instead of leaving hundreds of tabs open and having a bookmark bar instead of a tab bar is not bad at all.
I have come to believe that tab management is really the job of the window manager not individual apps. My window manager allows me to tile windows, or create tabs out of overlapping windows. The tabs can be from the same app or even different ones.
> I view "you might not need tmux" in the same way as "you might not need browser tabs".

A big difference is that I can move two browser tabs into separate windows, or from separate windows into the same.

The same is actually tree of top-level windows if your window manager can group windows into tabs.

tmux tabs lack this flexibility.

Tmux absolutely can move panes between windows, including into their own new window. And can move windows between sessions.
tmux can move windows from one session to another or to a new session. pretty much the way browsers move tabs around and create new windows. it can even have the same window in multiple sessions. i'd like to see a browser have the same (identical) tab in multiple windows.
MS Windows has excellent multi window management with Alt Tab Win Tab etc. Far superior to others.

I have all my terminals with distinct icons and background colours to tell them apart. The operating system (Windows) does the heavy lifting.

i tried Mac for about five years but missed MS Windows “every window can be alt tabbed to”. Mac has “every app can be command tabbed to and therein each app has its own subwindow management”

> MS Windows has excellent multi window management with Alt Tab Win Tab etc. Far superior to others.

If by "others" you mean Mac, okay, but KDE and some other Linux desktops are at least as good as Windows at this out of the box, and much more customisable.

Windows has basic window and desktop management, but I would hardly describe it as excellent. Most tiling window managers would provide those features and then more.
> “every app can be command tabbed to and therein each app has its own subwindow management”

This is so, so annoying. Your Mac app’s window is minimized? No alt-tab for you!

Just don’t minimize the window. Removing a window from the alt-Tab list is basically the only reason to minimize it in the first place on Mac. (Not reflexively minimizing windows does take some time to get used to if you’re coming from Windows, admittedly.)
Macs must have some strange workflows that that's the only use for minimizing...

I regularly minimize some applications when I want to focus on others.

Minimization on Mac is essentially a legacy feature. There’s rarely any reason to use it.
you can use workspaces for that. for comparison, gnome on linux doesn't even support minimizing windows any more. you move windows/apps that you don't want to use right now to a different workspace.
You can also hide an entire application rather than minimizing specific windows. It'll unhide when you switch back with cmd-tab.
gnome does do minimization fine but it's in the tweak tools. probably the first thing I change setting up a new system
On Windows there are applications that minimize to the tray instead of remaining on the task bar. That’s my most common reason to minimize, so that it disappears from the task bar when not in use.
Just CMD+TAB to your required app, then hit ↓ arrow and you get access to all your windows. Minimised windows appear at the bottom of the screen.
WindowMaker under GNU/Linux and BSD was like that too...

But, OFC, both WindowMaker and Mac OSX come from the same NeXT grandaddy...

well, windowmaker only copied the style, so it's more like a reverse adoption, not a descendant.
Not just that, even if Wing Is Not GNUstep. It was built to host tons of GNUStep applications and their behaviour.
i have used WindowMaker but also the original NeXTstep for years, and WindowMaker's integration with GNUstep apps and its emulation of the NeXTstep interface always felt incomplete.
Whatever fits your mental model I suppose, but every window is accessible via keyboard shortcuts on the Mac too, it just needs a different approach.
Do you know if there is a way to quickly switch between only two individual windows in different applications? A very common paradigm for me is swapping between two windows, for example a terminal session for code editing and a browser window for reference. On Windows and most Linux WMs, this is just a quick alt-tab hit to toggle between the two most recently focused windows. As I know there is no way to do this on macOS without bringing _all_ the windows to the foreground, which is not what I want. This is my #1 complaint about macos, I'd be so happy if there is just some shortcut I'm missing to accomplish this.
I'm pretty sure that's part of what stage manager is for — you can drag windows in the same stage and they operate how you want — but there's too much manual setup required for me to realistically suggest it as an alternative.

There are a bunch of third party tools you can use though, [AltTab](1) is free and tries to replicate windows experience on Mac. [Raycast](2) has a Switch Windows command which also allows direct access to any window via the keyboard (bind to alt+tab if you like) amongst many other features.

[1] https://alt-tab-macos.netlify.app/ [2] https://www.raycast.com/

Yeah unfortunately my work doesn't allow 3rd party apps like that (a reasonable restriction, IMO).
Control+F4 - ‘move focus to the active or next window’ is essentially that. (With the caveat that if your keyboard focus winds up on the menu bar or otherwise not on a window at all, control+f4 shifts focus back to the window, rather than switching windows. The main way to make that happen is with the other control-f-key shortcuts that no-one uses, though)

If you’re going to use it I’d probably rebind it in the keyboard shortcuts settings.

Doesn't seem to work for me, it looks like it cycles through all open windows instead of the most recently active window.
Alt-tab? You mean pressing win+w under CWM to fuzzy-find windows per title name, and then spawn it?
My tmux config has clickable tabs in one terminal.
that sounds interesting. there are a few terminals with tmux integration. which terminal are you using? could you share your config please?
This is on alacritty and Windows terminal. Look for the tmux config keys:

    # Show the status bar at the top
    set-option -g status-position top

    # Make the status bar always visible
    set-option -g status on
actually, the critical setting that matters is:

    set-option -g mouse on
that makes the tabs clickable. works in every terminal i tried it in.
But many terminals have tabs so if all you desire is more than one terminal open but not multiple ui windows there are other options. VSCode for instance!
byobu+tmux lets me log into a remote machine once and then have multiple named sessions/workspaces each having multiple named tabs. The sessions persist when I disconnect and are there when I reconnect the next day. Is that possible with terminal tabs?
That's why the browser tabs analogy breaks down.