Challenge - 5 Problems
Tag Mastery Badge
Get all challenges correct to earn this badge!
Test your skills under time pressure!
💻 Command Output
intermediate2:00remaining
Output of creating an annotated tag
What is the output of running the following command in a Git repository?
git tag -a v1.0 -m "Release version 1.0"
Git
git tag -a v1.0 -m "Release version 1.0"
Attempts:
2 left
💡 Hint
Annotated tags store extra information like messages but do not print output by default.
✗ Incorrect
The command creates an annotated tag with the given message. Git does not print any output when creating tags successfully.
🧠 Conceptual
intermediate2:00remaining
Difference between lightweight and annotated tags
Which statement correctly describes the difference between lightweight and annotated tags in Git?
Attempts:
2 left
💡 Hint
Think about what extra information annotated tags hold compared to lightweight tags.
✗ Incorrect
Lightweight tags are just names pointing to commits. Annotated tags include extra information like author, date, and a message.
🔀 Workflow
advanced2:30remaining
Correct sequence to create and push an annotated tag
What is the correct order of commands to create an annotated tag named v2.0 with message 'Second release' and push it to the remote repository?
Attempts:
2 left
💡 Hint
You must be on the correct branch before tagging, then push the tag, then update local info.
✗ Incorrect
First checkout the branch to tag, then create the annotated tag, push it to remote, and finally fetch to update local references.
❓ Troubleshoot
advanced2:00remaining
Error when pushing tags to remote
You created a tag locally using
git tag v3.0 but when you run git push, the tag does not appear on the remote. What is the reason?Attempts:
2 left
💡 Hint
Think about how Git handles tags during push operations.
✗ Incorrect
By default, 'git push' does not push tags. You must run 'git push origin --tags' or 'git push origin ' to push tags.
✅ Best Practice
expert3:00remaining
Recommended practice for tagging releases in a team
Which practice is best when multiple developers create tags for releases in a shared Git repository?
Attempts:
2 left
💡 Hint
Think about coordination and clarity in a team environment.
✗ Incorrect
Agreeing on naming conventions and pushing tags immediately helps keep the team synchronized and avoids confusion.