0
0
Gitdevops~10 mins

Garbage collection with git gc - Interactive Code Practice

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

Complete the command to run garbage collection in Git.

Git
git [1]
Drag options to blanks, or click blank then click option'
Acommit
Bclone
Cgc
Dpush
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'commit' instead of 'gc' will create a commit, not clean up files.
Using 'push' sends changes to a remote, not garbage collection.
Using 'clone' copies a repository, not related to garbage collection.
2fill in blank
medium

Complete the command to run garbage collection with aggressive optimization.

Git
git gc --[1]
Drag options to blanks, or click blank then click option'
Afast
Baggressive
Cquiet
Dverbose
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'fast' does not exist as an option for git gc.
Using 'quiet' suppresses output but does not affect optimization level.
Using 'verbose' increases output detail but not optimization.
3fill in blank
hard

Fix the error in the command to prune unreachable objects during garbage collection.

Git
git gc --prune=[1]
Drag options to blanks, or click blank then click option'
Anow
Bnever
Calways
Dlater
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'never' means no pruning happens.
Using 'always' is not a valid prune option.
Using 'later' is not recognized by git gc.
4fill in blank
hard

Fill both blanks to run garbage collection quietly and prune objects older than 2 weeks.

Git
git gc --[1] --prune=[2]
Drag options to blanks, or click blank then click option'
Aquiet
Bnow
C2.weeks.ago
Dverbose
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'verbose' instead of 'quiet' will increase output.
Using 'now' prunes immediately, not older than 2 weeks.
Mixing options incorrectly can cause errors.
5fill in blank
hard

Fill all three blanks to run aggressive garbage collection, prune immediately, and show verbose output.

Git
git gc --[1] --prune=[2] --[3]
Drag options to blanks, or click blank then click option'
Aaggressive
Bnow
Cverbose
Dquiet
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'quiet' instead of 'verbose' hides output.
Using 'later' or invalid prune values causes errors.
Omitting aggressive makes optimization less thorough.