Git merge squash up:: Git Say your bug fix branch is called bugfix and you want to merge it into main: git checkout main git merge --squash bugfix git commit