Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Why does sourcetree show a single branch after a merge?

Michael Schamber May 17, 2023

I'm new to git and sourcetree, and I recently encountered an issue where there is no merge commit and all my branches are collapsed after I merged develop into main (first merge was the UPDATE:increment version to 1.0.0 commit). No matter what branch I switch to, it always displays as a single line. If I make changes to a single branch, it doesn't represent them graphically as distinct branches. This can be seen below:

Screenshot 2023-05-17 at 8.52.03 AM.png

 

But in another repo, everything functions as normal:Screenshot 2023-05-17 at 8.58.06 AM.png

 

Has anyone encountered this before? I tried to search for a solution or cause, but didn't see anything. The only thing that stands out to me is that one is showing a remote HEAD while the other does not.

Thanks for the help!

1 answer

1 accepted

0 votes
Answer accepted
Michael Schamber May 17, 2023

Managed to solve the issue. 
I'm not sure why, but the one repo was merging via fast-forward so it was not creating a commit.

After performing a hard reset of the main branch to the initial commit, I selected "create a commit even if merge resolved via fast-forward" and now the branches and merge commit are present. 


Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events