Sarav's Weblog

Technical Articles for RoR Developers

Remove a remote Git branch and tags


Removing a branch from your remote repo is a little bit different from removing it locally. It’s all about the colon:

Example:

git push origin :heads/some-branch
git push origin :your_branch_name

removes some-branch from the remote repo (apparently git push origin :some-branch works as well).

This works for removing a tag as well:

git push origin :sometag

I found it in the git guides posting it here for *my* reference, and possibly other people as well.

cheers.

Advertisements

One response to “Remove a remote Git branch and tags

  1. Brianna Neddo April 4, 2010 at 7:47 am

    Hey, I found your blog while searching on Google your post looks very interesting for me. I will bookmark your site. Keep up the good work!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: