Re: Deleting remote branches

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 25, 2010 at 10:09:03PM -0800, jhapk wrote:
> 
> Hi,
> 
> I have tried that and I get the following message
> 
> [pradeep@scaramanga cffc]$ git push origin:test
                                      ^^^^^^^^^^^

Notice the missing space. From the git push manpage:

git push origin :experimental
               ^
    Find a ref that matches experimental in the origin repository (e.g.
    refs/heads/experimental), and delete it.


The syntax (with all the unused stuff removed) is 'git push <repository> <refspec>'
If you don't supply any repository (as you did with your cmdline), the default 
remote repository is used. Your command tried to push the local branch 'origin' into
the remote branch 'test' of your default remote repository. Correct would be

git push :test   # or git push origin :test

The refspec :test means push empy/nothingness into the branch 'test', which will delete it.

--
Peter
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]