Help the world stop coronavirus! Stay home!

Prev Next

Maven / GIT Interview Questions

How do I view the file changes (diff) before committing in GIT?

Use the git diff comand as shown below.

git diff "filename_to_diff"

The above command works only when the file is not added already. If it is added already, use the same command with cached option as shown below.

git diff --cached  "filename_to_diff"

❤Cash Back At Stores you Love !!!❤

Earn your $10 reward when you make your first purchase through Ebates by signing up with clicking below button.

Ebates Coupons and Cash Back

More Related questions...

Show more question and Answers...


Comments & Discussions