I created a branch on the release-1.0 server

This is how it looks

 aleksey@aleksey:~/Downloads/NTZ/FittingRoom$ git branch -a * develop release-1.0 remotes/origin/HEAD -> origin/master remotes/origin/develop remotes/origin/master remotes/origin/release-1.0 

Now I did merge with the master and I want to remove it, I write such a command

 $ git branch -d origin/release-1.0 

and it shows me that there is no such branch ...

And what is more interesting is that when I made the release of the remote branch and the master branch deleted, everything went well and I also hung the tag on it ...

Then he switched from branch to branch and went back to the remote master, but there is no this last merge ... Strange ...

  • Without origin/ , git branch -d release-1.0 - stackanon
  • So if I do this, the local branch will be deleted ... And I need to remove the remote ... - Aleksey Timoshchenko

1 answer 1

Starting from version 1.7.0, you can delete a ветку in a remote (tautology, yes) repository (for example, origin ) with:

 $ git push origin --delete ветка 

which is probably somewhat easier to remember than the “old” format:

 $ git push origin :ветка 
  • one
    ... in which it makes sense if you know what the сервер что:куда , where, что could be "nothing". But the new form is definitely clearer, yes. - D-side
  • one
    @ D-side and I like the old form. Push "nothing" into the thread. - Nick Volynkin