0

I did a git checkout and made some changes while in the detached head state. I commited the changes. How do I apply these changes to a specific branch? Can I checkout that branch and then do a git merge?

Thanks in advance for the help!

Keith Johnson
  • 730
  • 2
  • 9
  • 19

1 Answers1

1

You can just make a new branch

If you want to keep them by creating a new branch, this may be a good time
to do so with:

 git branch new_branch_name <SHA of commit>

Get a series of commits on a detached head onto a branch

Community
  • 1
  • 1
Zombo
  • 1
  • 62
  • 391
  • 407