What is the difference between rebasing and merge in git?
Answer / Amit Kumar Batar
Rebasing and merging are two common methods for integrating changes from one branch to another in Git. Here's a summary of their differences:n1. Rebase: When you rebase, you move or combine a feature branch onto another branch. This results in a linear history where the features are built on top of the latest version of the target branch, rather than having multiple independent lines of development. However, rebasing can be confusing if others are also working on the same branches as it will appear as though commits are being rewritten.n2. Merge: When you merge, you combine changes from another branch into your current branch. This creates a new commit that represents the merge point between the two branches. The original commits remain intact, and there's no linearization of the history like with rebasing. Merging is typically less disruptive to others working on the same project because it doesn't change the commit history.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the function of ‘git checkout’ in git?
Explain git stash, pop?
How do you find a list of files that have changed in a particular commit?
What is ‘git status’ is used for?
What language is used in GIT?
Explain the advantages of forking workflow?
What is git bisect and what is its purpose?
How git instaweb is used?
Name a few git commands and explain their usage.
What is git reflog?
What is subgit?
What is a repository and how will you create it?