0
0
Gitdevops~5 mins

Repository (committed history) in Git - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is a repository in Git?
A repository is a storage space where your project files and their entire history of changes are saved. It keeps track of all versions of your files.
Click to reveal answer
beginner
What does git commit do?
It saves a snapshot of your current changes to the repository's history. Think of it like taking a photo of your project at a moment in time.
Click to reveal answer
beginner
Why is committed history important?
Committed history lets you see what changed, when, and who changed it. It helps you fix mistakes by going back to earlier versions.
Click to reveal answer
intermediate
What is a commit hash?
A commit hash is a unique ID for each commit. It looks like a long string of letters and numbers and helps you find that exact snapshot later.
Click to reveal answer
beginner
How can you view the committed history in Git?
Use the command git log to see a list of commits with details like author, date, and message.
Click to reveal answer
What command saves your changes to the Git repository history?
Agit clone
Bgit push
Cgit commit
Dgit status
What does the commit hash represent?
AA unique ID for each commit
BThe size of the repository
CThe name of the branch
DThe current working directory
Which command shows the list of past commits?
Agit branch
Bgit log
Cgit add
Dgit init
Why is committed history useful?
ATo track changes and fix mistakes
BTo delete files permanently
CTo speed up your computer
DTo create new files automatically
What happens if you don’t commit your changes?
ARepository is deleted
BChanges are automatically saved
CGit creates a new branch
DChanges are not saved in history
Explain what a Git repository's committed history is and why it matters.
Think about how saving versions of a document helps you go back if needed.
You got /4 concepts.
    Describe the role of the git commit command in managing repository history.
    Imagine taking a photo of your project to remember its state.
    You got /4 concepts.