B
B
Boris Dergachev2015-11-13 19:51:03
git
Boris Dergachev, 2015-11-13 19:51:03

How to get rid of forgotten git branches?

My repository traces the history shown below
a9350ab71c9446aeb5c4a9965118e942.png
Branches without a continuation have no name, git branch -athey are not visible on command. I would like to get rid of such branches in the remote repository. How can I do this if I only know the commit hash?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
aol-nnov, 2015-11-13
@aol-nnov

I would start with

git fetch origin
git remote prune origin

then I would go to that remote through the shell and do git gc there (although, usually, it should be done there itself)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question