mirror of
https://github.com/tj/git-extras.git
synced 2026-09-10 07:26:17 -04:00
when there's a tag and a branch with the same name, git errors out with `error: dst refspec MY_BRANCH matches more than one.` git-delete-tag is not affected by this bug
8 lines
169 B
Bash
Executable file
8 lines
169 B
Bash
Executable file
#!/bin/sh
|
|
|
|
branch=$1
|
|
test -z $branch && echo "branch required." 1>&2 && exit 1
|
|
git branch -D $branch
|
|
git branch -d -r origin/$branch
|
|
git push origin :refs/heads/$branch
|