Help us understand the problem. What is going on with this article?

[git merge --squash]commitを1つにまとめてと言われたら。

More than 1 year has passed since last update.



作業ブランチのマージ先: develop
作業ブランチ: feature/example_999
一時作成用ブランチ: tmp

$ git checkout feature/example_999 # 作業ブランチへ移動しておく
$ git branch -m feature/example_999 tmp # -m ブランチ名を変える
$ git checkout develop # 作業ブランチのマージ先ブランチに切り替える
$ git checkout -b feature/example_999 # 作業ブランチと同じ名前のブランチを作成
$ git merge --squash tmp # 1つにまとめる
$ git commit -m "squash" # commit
$ git push origin feature/example_999 -f # push
$ git branch -D tmp # tmpブランチを削除
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away