高度な Git
Amanda Crawford-Adamo
Software and Data Engineer

Git merge コマンド:
git merge

ファストフォワード マージとは?
$$
避けるべき場合

Git のデフォルト: ファストフォワード マージ
git checkout main
git merge feature_branch
ファストフォワードを強制
git merge <branch> --ff-only
例
git checkout main
git merge feature_branch --ff-only

リカーシブマージとは?
$$
避けるべき場合

リカーシブマージのコマンド:
git merge --no-ff <branch>
例
$ git checkout main
Switched to branch 'main'
Your branch is up to date with 'origin/main'.
$ git merge --no-ff feature_branch
Merge made by the 'recursive' strategy.
...

ファストフォワードのコマンド
git merge <branch_name> # 既定
git merge --ff-only <branch_name> # FF を強制
リカーシブのコマンド
git merge --no-ff <branch_name>
高度な Git