Skip to main content
I liked the long title.
Source Link
Erik B
  • 42.1k
  • 27
  • 123
  • 140

Git: "Not currently on any branch." Is there an easy way to get back on a branch, while keeping the changes?

So I've done some work in the repository and when I'm about to commit I realize that I'm not currently on any branch.

The error is:

Not currently on any branch.

This happens a lot when working with submodules and I am able to solve it, but the process is tedious and I've been thinking that there must be an easier way to do this.

Is there an easy way to get back on a branch, while keeping the changes?

Is there an easy way to get back on a branch, while keeping the changes?

So I've done some work in the repository and when I'm about to commit I realize that I'm not currently on any branch.

The error is:

Not currently on any branch.

This happens a lot when working with submodules and I am able to solve it, but the process is tedious and I've been thinking that there must be an easier way to do this.

Is there an easy way to get back on a branch, while keeping the changes?

Git: "Not currently on any branch." Is there an easy way to get back on a branch, while keeping the changes?

So I've done some work in the repository and when I'm about to commit I realize that I'm not currently on any branch.

This happens a lot when working with submodules and I am able to solve it, but the process is tedious and I've been thinking that there must be an easier way to do this.

Is there an easy way to get back on a branch, while keeping the changes?

Shortening the title.
Source Link
kenorb
  • 162.9k
  • 94
  • 697
  • 763

Git: "Not currently on any branch." Is there an easy way to get back on a branch, while keeping the changes?

So I've done some work in the repository and when I'm about to commit I realize that I'm not currently on any branch.

The error is:

Not currently on any branch.

This happens a lot when working with submodules and I am able to solve it, but the process is tedious and I've been thinking that there must be an easier way to do this.

Is there an easy way to get back on a branch, while keeping the changes?

Git: "Not currently on any branch." Is there an easy way to get back on a branch, while keeping the changes?

So I've done some work in the repository and when I'm about to commit I realize that I'm not currently on any branch. This happens a lot when working with submodules and I am able to solve it, but the process is tedious and I've been thinking that there must be an easier way to do this.

Is there an easy way to get back on a branch, while keeping the changes?

Is there an easy way to get back on a branch, while keeping the changes?

So I've done some work in the repository and when I'm about to commit I realize that I'm not currently on any branch.

The error is:

Not currently on any branch.

This happens a lot when working with submodules and I am able to solve it, but the process is tedious and I've been thinking that there must be an easier way to do this.

Is there an easy way to get back on a branch, while keeping the changes?

[no-branch] is too minor of a tag.
Link
JasonMArcher
  • 14.7k
  • 22
  • 58
  • 52
edited title
Link
Erik B
  • 42.1k
  • 27
  • 123
  • 140
Loading
Source Link
Erik B
  • 42.1k
  • 27
  • 123
  • 140
Loading