cli.fail

Practice this fail.

My changes vanished. Allegedly.

Git · Restart as often as you like

Read the error, choose a command, and learn
why it works. Nothing runs on your machine.

Browse all practice ↗

You edited src/app.js and successfully ran git add src/app.js. The working file now matches the staged version.

My changes vanished. Allegedly.

$ git add src/app.js

$ git diff

(no output)

How do you see the exact changes staged for the next commit?

3 attempts remaining

Read why this fix works

My changes vanished. Allegedly.

git diff --cached

Plain git diff compares working files with the staging area. Once both copies match, that comparison is empty. git diff --cached compares the staging area with HEAD, showing the actual changes prepared for the next commit.

Practice rounds do not affect the daily score or local streak. Try today’s challenge, or choose another scenario.

Copy your result