Switching Modes
Yggdrasil offers three distinct modes when you choose to switch to a worktree. This allows you to tailor your workflow to the task at hand.
Switch Modes
- New Window: Opens the selected worktree in a completely new VS Code instance. Great for cross-referencing code or working on two branches simultaneously.
- Replace Current: Closes the current folder/workspace and opens the selected worktree in the same window. Best for a clean context pivot.
- Add to Workspace: Adds the worktree folder to your current VS Code window, creating a Multi-root Workspace. Ideal for managing related changes across multiple branches.
Remembering Your Choice
The switch dialog includes a “Remember my choice” checkbox.
- If checked, Yggdrasil will skip the dialog in the future and always use your selected mode.
- A status bar item will appear at the bottom of the editor, showing your current preference (e.g., “Ygg: New Window”).
- You can click the status bar item or run the
ygg.clearSwitchModecommand to reset this preference and bring back the dialog.