mirror of
https://github.com/mike-rambil/Advanced-Git.git
synced 2025-12-30 05:59:31 -06:00
684 B
684 B
⬅️ Back to How to Use git worktree Safely
⬆️ Previous Step: Remove a Worktree
Switch Between Worktrees
Command
cd <worktree-path>
Examples
- Switch to the worktree directory.
cd ../feature-branch```
- **Switch to a hotfix worktree.**
```sh
cd ../hotfix```
#### Steps
1. Simply cd into the worktree directory to switch.
[➡️ See the Next Step: Use Worktrees for Temporary Fixes](./use-worktrees-for-temporary-fixes.md)
---
_Author: mike-rambil • Updated: 2024-06-10 • Tags: worktree, switch_