mabots' blog

知のレバレッジを最大化せよ (旧はてなダイアリーから移転しました。)

git remote branch の削除

github で merge 後に remote branch 削除。その後 local の不要 branch を push してしまった場合などに remote に不要 branch が残ってしまいます。いつも微妙に忘れてしまうので、この場合のメモ。

  • local branch を削除
$ git branch -D local/branch
  • 削除した内容を push
$ git push origin :local/branch