Git · Junior · Question 62 of 75

What does git mv old.js new.js do?

Explanation

Git doesn't store renames explicitly; it detects them by comparing content. git mv is a shortcut for renaming plus git rm and git add.

Further reading

Problem with a question

Git · Junior · question 62

Test yourself

Take the Git · Junior quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz