Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Somehow indicate that there is new output in a tab #1050

Closed
Tobbe opened this issue Aug 20, 2021 · 5 comments
Closed

Somehow indicate that there is new output in a tab #1050

Tobbe opened this issue Aug 20, 2021 · 5 comments
Labels
enhancement New feature or request

Comments

@Tobbe
Copy link

Tobbe commented Aug 20, 2021

Is your feature request related to a problem? Please describe.

This feature would help with two things when having multiple tabs open

  1. I sometimes fire off a task that takes several seconds (or longer) to complete. While waiting for that I switch to other tabs to continue working there. Some kind of indication of new output would (depending on the nature of the task) help show when the task has completed without me having to constantly switch to the tab to check if it's done or not.
  2. If I have a forever-running process in a couple of tabs that constantly produces output some kind of indication of new output would allow me to quickly identify what tabs have these processes running so I can switch to them to check their output or switch to them to kill the process if that's what I want

Describe the solution you'd like

Another terminal I use adds an asterisk (*) to the end of the tab title to indicate new output. Other options could be to change tab color, underline tab title, change tab border color, or any other kind of visual indicator.

Describe alternatives you've considered

What I'm really looking for is 1. A way to know that a task has completed in an inactive tab. 2. Know what tabs have forever-running processes. Any other way to solve those two use-cases that's not just indicating new output is obviously also welcome 🙂. Like maybe add a 🔄 icon to tabs with long-running processes. And then when/if they finish, change to a ✅ or ❌ icon depending on exit code.

Additional context

Nope

@Tobbe Tobbe added the enhancement New feature or request label Aug 20, 2021
@wez
Copy link
Owner

wez commented Aug 20, 2021

A couple of things to consider:

There's a little bit of conceptual overlap with #3

Configuring Shell Integration would teach your shell to advise wezterm of prompting and output states through the use of OSC 133 semantic zones. We could potentially teach wezterm to generate an internal event when the zone type in a pane changes. The semantic escapes also allow for recording information about running commands and their exit results which could also be plumbed through in a similar way.

In the meantime, you may be able to satisfy yourself with a little bit of playing around with your shell dotfiles and your wezterm config; take a look at the discussion on #647 wherein user vars are used to convey information from the shell to the tab formatting function and color the tab based on its state.

@wez
Copy link
Owner

wez commented Aug 20, 2021

In terms of output-since-last-examined, the underlying pane object has a sequence number representing the "time" that the pane was last changed. We could track the last rendered sequence number in the gui state alongside the other per-pane data that we track. Those two pieces of data could feed into the tab formatting to decide if there's been information since the last render.

@wez
Copy link
Owner

wez commented Jan 19, 2022

I forgot that we had this issue as well as this discussion; I pushed some changes and posted about them over here:
#796 (reply in thread)

@wez
Copy link
Owner

wez commented Mar 26, 2022

this feature is available in the current release; documentation and example towards the bottom of https://wezfurlong.org/wezterm/config/lua/PaneInformation.html

@wez wez closed this as completed Mar 26, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Feb 4, 2023

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 4, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants