3 ms·
I've recently coded something like this, however with significant differences from what OP is presenting. Here are the most important differences: - Using a zs
by da-x 6y ago
I've recently coded something like this, however with significant differences from what OP is presenting. Here are the most important differences:
- Using a zsh plugin, it works for every command that I run, but only if I need it, so it doesn't create extra noise. Meaning, it is automatically activated for terminals that go out of focus. I don't need a special suffix to activate it. I recently contributed a tmux pull request just for that [1].
- It's a fixed size, flashing window in a side monitor, so if I got off the chair after execution started, I still notice the termination when I return to my workstation.
- If I change my focus back to the unfocused terminal where the termination happened, the notification disappear by itself (no extra action needing to click the 'x'!).
- It contains information regarding the tmux pane in which the termination has happened. This is needed, because I have multiple tmux sessions each having multiple windows with multiple panes in it, and all this on top of multiple XFCE workspaces.
- It's a server-client architecture, so clients running on separate host shells can run on a different computer and am able to send over termination notifications to the server that hosts the GUI (my workstation desktop).
[1] https://github.com/tmux/tmux/pull/2558 https://github.com/tmux/tmux/pull/2558