Câu hỏi phỏng vấn Git
Câu hỏi

When should I use git stash ?

Câu trả lời

Here are some key situations when you should use git stash:

When to Use git stash

1. When you need to switch branches

If you're working on one branch and realize you need to quickly switch to another branch to fix a bug or merge in some changes, you can use git stash to temporarily save your current work-in-progress without having to commit it.

2. When you want to experiment

If you want to try out some experimental changes or a new feature without affecting your main codebase, you can stash your current changes, switch to a new branch, and then apply the stashed changes later if needed.

3. When you need to pull the latest changes

If you need to pull the latest changes from a remote repository but have local uncommitted changes, you can stash your changes, pull the latest c...

junior

junior

Gợi ý câu hỏi phỏng vấn

expert

How can you use git bisect to determine the source of a (regression) bug?

middle

What is git cherry-pick ?

middle

Could you explain the Gitflow workflow?

Bình luận

Chưa có bình luận nào

Chưa có bình luận nào