14
14

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

GitHubでプルリクエストをマージしてブランチを消したあとの流れ

Last updated at Posted at 2020-09-24

概要

  • プルリクエストをマージしたあとに、GitHub側(remote側)のブランチを消したあとの流れがよく分からなかったので整理してみた。

前提

  • 書いた人は普段業務でSubversionしか使ってない人です。
  • 以下のブランチがあることを想定
    • mainブランチ
    • featureブランチ
  • 今回、feature → mainにマージして、featureブランチを削除する

手順

  1. プルリクエストがマージされたときにGitHub上のfeatureブランチを削除
  2. ローカル側でmainブランチに移動 git checkout main
  3. GitHub側のmainブランチにマージした内容を、ローカルのmainブランチに反映する git pull origin main
  4. ローカル側のfeatureブランチを削除する git branch -d feature
14
14
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
14
14

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?