Thank you, Konstantin.
Here's a brief explanation to "git push [remote] :[branch]" syntax: => "Deleting Remote Branches"

On Sep 15, 11:49 pm, Konstantin Khomoutov <> wrote:
> On Sep 15, 5:41 pm, Roddie Grant <> wrote:
> > With a moment's inattention I typed
> > git push test databaseTests:refs/remotes/dev/databaseTsts
> > instead of
> > git push test databaseTests:refs/remotes/dev/databaseTests
> > and now in the test repos the listing from git br -a includes
> > remotes/dev/databaseTsts
> > git br -d remotes/dev/databaseTsts
> > results in
> > error: branch 'remotes/dev/databaseTsts' not found.
> > How do I delete the mis-named branch?
> git-branch only operates on local branches and any tinkering with
> remotes goes via git-push.
> To rename a wrongly-named remote branch delete it and push under a
> correct name; deleting is done by pushing an empty refspect (see the
> git-push manual).
> Hence do this:
> $ git push test :databaseTsts databaseTests
> this will a) delete a remote object named "databaseTsts"; b) push a
> local object "databaseTests" to the same named remote object.
> Note that you don't really understand why do you need that "refs/
> remotes/dev/" prefix -- git usually does just the right thing when you
> supply short names to git-push.

You received this message because you are subscribed to the Google Groups "Git 
for human beings" group.
To post to this group, send email to
To unsubscribe from this group, send email to
For more options, visit this group at

Reply via email to