0
0
Gitdevops~10 mins

git blame for line-by-line history - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the command to show who last changed each line in a file named README.md.

Git
git [1] README.md
Drag options to blanks, or click blank then click option'
Ablame
Bstatus
Clog
Ddiff
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'git log' instead of 'git blame' to see line history.
Using 'git status' which shows file changes but not line history.
2fill in blank
medium

Complete the command to show blame info for line 10 only in file app.py.

Git
git blame -L [1],[2] app.py
Drag options to blanks, or click blank then click option'
A10,10
B1,10
C10,20
D5,10
Attempts:
3 left
💡 Hint
Common Mistakes
Using a range that includes multiple lines instead of just one.
Forgetting to specify both start and end line numbers.
3fill in blank
hard

Fix the error in the command to show blame for file main.c in porcelain format.

Git
git blame --[1] main.c
Drag options to blanks, or click blank then click option'
Aauthor-name
Bshow-author
Cporcelain
Dname-only
Attempts:
3 left
💡 Hint
Common Mistakes
Using incorrect option names like '--show-author' or '--name-only'.
Using single dash instead of double dashes.
4fill in blank
hard

Fill both blanks to limit blame output to lines 5 to 15 and ignore whitespace changes.

Git
git blame -L [1],[2] --[3] file.txt
Drag options to blanks, or click blank then click option'
A5
B15
Cignore-whitespace
Dignore-all-space
Attempts:
3 left
💡 Hint
Common Mistakes
Using wrong line numbers or reversed order.
Using incorrect whitespace ignore options.
5fill in blank
hard

Fill all three blanks to show blame for file server.js, limit to lines 20-30, in porcelain format with abbreviated commit hashes.

Git
git blame [1] [2] [3] server.js
Drag options to blanks, or click blank then click option'
A-L 20,30
B--porcelain
C--abbrev
D--show-name
Attempts:
3 left
💡 Hint
Common Mistakes
Using options in wrong order or missing line limit.
Confusing options that show author names instead of hashes.