Prepare Interview

Mock Exams

Make Homepage

Bookmark this page

Subscribe Email Address

GIT Interview Questions and Answers

Ques 6. Explain the purpose of 'git pull' command.

'git pull' is used to fetch and merge changes from a remote repository to the current branch.

Is it helpful? Add Comment View Comments
 

Ques 7. How do you undo the last Git commit?

You can use 'git reset HEAD~1' to undo the last commit without discarding the changes.

Is it helpful? Add Comment View Comments
 

Ques 8. What is the difference between 'git rebase' and 'git merge'?

'git rebase' integrates changes from one branch to another by applying them individually, while 'git merge' combines changes as a single commit.

Is it helpful? Add Comment View Comments
 

Ques 9. What is the purpose of the '.gitignore' file?

The '.gitignore' file specifies files and directories that should be ignored by Git, preventing them from being tracked in the repository.

Is it helpful? Add Comment View Comments
 

Ques 10. Explain the concept of Git branching.

Git branching allows developers to create independent lines of development, enabling them to work on features or bug fixes without affecting the main codebase until ready.

Is it helpful? Add Comment View Comments
 

Most helpful rated by users:

©2025 WithoutBook