You stashed WIP while on `main`. It was actually feature work. You want it on a new branch instead.
Create the branch you meant to be on, switch to it, then pop the stash there.
Medium · 3 steps · +500 XP
This scenario walks through 3 steps, in order:
Try the terminal first — you learn more by doing. When you want to check yourself, here is the command for each step.
git stash listgit switch -c feature/from-stashgit stash pop`git stash branch <name>` bundles these two moves into one command — it branches from the commit the stash was taken on, then pops. Doing it by hand is switch + pop.