-
Notifications
You must be signed in to change notification settings - Fork 34.7k
Description
This is a plan for terminal tabs issue: #10546, I read through all the comments on that issue while coming up with the below.
If you have feedback on this feature, please put it in #10546
Philosophy
The terminal view is convenient, it's nice to have all terminals in a single space where you can reliably go to in order to see all your terminals. Having said that, some people don't like the terminal panel and would prefer to work with editors. There are a few reasons for this:
- They want to use a true grid view with more than 1 dimension - this isn't implemented in the terminal view to keep things simple and lightweight.
- They want terminals that are persistent and will always be visible regardless of panel state.
- They want to save the panel's real estate for something else like the debug console or problems.
- They want to make better use of monitors.
- They want to temporarily use a terminal on the side to give it more real estate and use as a reference - this is something I use a text editors in a second editor group for.
- They want to have a single full screen editor group, being able to switch to the terminal without messing with its dimensions
The plan is to make terminal editors optional/opt-in. If the user doesn't want to use them, then they probably wouldn't even notice they exist. Terminal editors will complement the existing terminal tabs, both can be used if the user wants.
Tasks
For an up to date list of tasks check this query.
- MVP - merge to main when done
- Terminal Editors: Support transferring terminal processes to/from editors #126243 @Tyriar
- Settings
- Terminal Editors: Support reconnect #126250 @meganrogge
- Terminal Editors: Support in term quick access #126252 @meganrogge
- Terminal Editors: Some important commands work don't work in terminal editors #126471 @meganrogge
- Drag and drop
- Context menus
- 💪 Terminal Editors: Add + terminal button #126256
- 💪 Support contributed profiles in terminal editor + button #127158
- Terminal Editors: Show icon, color and status in tabs #126689 @Tyriar
- add find widget to terminal editors #126525 @meganrogge
- 💪 Terminal editors should be marked as dirty when the shell has child processes #127193
Verification
List of some things to make sure that they work during development and also to add to the test plan at the end of the iteration.
- Ensure API
Terminal.show
works for terminal editors - Ensure tab color, icon works for terminal editors
- Status works for terminal editors, including the task running animation
- Ensure status hover shows when hovering terminal editor tabs
- Backgrounded terminal editors on reload should be restored correctly - the process should reconnect but the editor should not be created until focused
- Ensure terminal editors are always pinned
- Linux/Windows: Does ctrl+w close the tab as expected? (tracked in Ctrl+w should close terminal editors by default #127189)
- Does split editor (cmd/ctrl+) work as expected within the terminal editor?
- Does split terminal command work as expected within the terminal editor?
- Reconnected terminal editors don't resize terminal unless the window size has changed
- Work as expected in test resolver?
- Work as expected in Web?
- Try live share
Investigations
Some unknowns/explorations to consider after the main parts are done.
- Consider setting to include editor terminals in next/previous terminal commands?
- Will wait for feedback, editor nav commands will likely be enough
- Investigate lock editor group/secondary editor concept - Deferred to Explore ways to not pollute editor groups with terminals with other editors #124709
- Keybindings? Create terminal is option+T in Cloud9
- Let's leave keybindings out of the initial release, option+T seems like an odd choice, maybe better ideas will come in
- How should ctrl+shift+t interact with closed terminal editors? Should the processes stick around for x seconds in case it was closed accidentally?
- Always prompt for terminal editors?
- confirmOnExit interaction? Terminal confirmOnExit should only warn when the terminal shell is running something #23808
- Will wait for feedback
- Is there anything else we should do wrt discoverability?
- I think this is covered sufficiently with context menus, dragging and dropping and the registered commands
- Support detaching terminals Support detaching terminal processes #118276
- Do a once over of all terminal commands, are there any others we need to handle specially?
- Can/should the terminal editor code be loaded asynchronously since it's an optional feature?
- Not possible due to how editors are registered, saving would also be very minimal and probably not worth it anyway
- Breadcrumbs integration? Show cwd on macOS/Linux?
- Will wait for feedback
References
- Atom terminal-tab https://atom.io/packages/terminal-tab, Tabs for integrated terminal #10546 (comment)
- VS Code Terminal Tab extension using webviews by @mmis1000 https://github.com/mmis1000/Vscode-terminal-tab