You need to the merge the POC branch into the default branch. The solution must meet the technical requirements.
Which command should you run?
A. git rebase
B. git merge --squash
C. git push
D. git merge --allow-unrelated-histories
Which command should you run?
A. git rebase
B. git merge --squash
C. git push
D. git merge --allow-unrelated-histories
Answer : A
✅ Explanation
-The commit history of the POC branch must replace the history of the default branch.
-Rebasing is the process of moving or combining a sequence of commits to a new base commit. --------Rebasing is most useful and easily visualized in the context of a feature branching workflow. The general process can be visualized as the following:
-Note: The primary reason for rebasing is to maintain a linear project history. For example, consider a situation where the main branch has progressed since you
started working on a feature branch. You want to get the latest updates to the main branch in your feature branch, but you want to keep your branch's history
clean so it appears as if you've been working off the latest main branch. This gives the later benefit of a clean merge of your feature branch back into the main
branch. Why do we want to maintain a "clean history"? The benefits of having a clean history become tangible when performing Git operations to investigate
the introduction of a regression.
✅ Explanation
-The commit history of the POC branch must replace the history of the default branch.
-Rebasing is the process of moving or combining a sequence of commits to a new base commit. --------Rebasing is most useful and easily visualized in the context of a feature branching workflow. The general process can be visualized as the following:
-Note: The primary reason for rebasing is to maintain a linear project history. For example, consider a situation where the main branch has progressed since you
started working on a feature branch. You want to get the latest updates to the main branch in your feature branch, but you want to keep your branch's history
clean so it appears as if you've been working off the latest main branch. This gives the later benefit of a clean merge of your feature branch back into the main
branch. Why do we want to maintain a "clean history"? The benefits of having a clean history become tangible when performing Git operations to investigate
the introduction of a regression.