ChrisRich
ChrisRich

Reputation: 8736

VSCode extension: Save and restore tab groups

As a developer doing context switching all day long I want to save groups of open tabs and restore them later (within the same project window).

E.g when I am asked to "work on feature A" I want to open all of the tabs for that project relating to "feature A".

I spend way too much time searching for files closing, opening tabs and scrolling along the tab bar to find what I need.

Working on 5 different features in a day I need to quickly switch my editor to reflect what I am working on.

Are there any built in features or extensions for this?

Upvotes: 14

Views: 4372

Answers (2)

iHaveAQuestion
iHaveAQuestion

Reputation: 313

I am facing the same issues too and just came across this VS Code extension: Editor Group Minimizer. It provides the functionality of saving and restoring VS Code tabs.

GIF from the VS Code extension marketplace

Upvotes: 14

Ivailo Manolov
Ivailo Manolov

Reputation: 38

The only way I have found so far:

VSCode: Store and reopen a group of file tabs so that I reset a specific environment in the future

To save a snapshot you use two extensions and modify tasks.json. To open the editors you just have to run the task. It happens quicker than it sounds after you set up (just do some copy-paste to settings.json, keybindings.json and tasks.json) the extensions. The usage procedure is:

  1. To save a snapshot
    • Run "Tasks: Configure task" command to open tasks.json
    • Copy or use an existing task
    • [optional] Change task's name
    • [optional] add or remove "dependsOn": [ "close all editors" ]
    • Ctrl + Shift + i (or perhaps another keybinding)
    • Save tasks.json
  2. To open a snapshot: "Tasks: Run Task" and choose the task you need.

Upvotes: 1

Related Questions