0
0
Gitdevops~5 mins

The .git directory structure - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What is the purpose of the .git directory in a Git project?
The .git directory stores all the information Git needs to track changes, history, branches, and configuration for the project. It is the heart of the Git repository.
Click to reveal answer
beginner
What does the HEAD file inside the .git directory represent?
The HEAD file points to the current branch or commit that your working directory is based on. It tells Git what you are currently working on.
Click to reveal answer
intermediate
What is stored in the objects folder inside the .git directory?
The objects folder contains all the content Git tracks, saved as compressed files. These include commits, trees (folders), and blobs (file contents).
Click to reveal answer
intermediate
What is the role of the refs directory inside .git?
The refs directory holds references to commit objects, such as branches and tags. It helps Git know where branches and tags point in the commit history.
Click to reveal answer
beginner
What kind of information is stored in the config file inside the .git directory?
The config file stores repository-specific settings like remote URLs, user info, and other Git options that affect how Git behaves in this project.
Click to reveal answer
Which folder inside .git contains the actual data of commits and files?
Ahooks
Brefs
Cobjects
Dlogs
What does the HEAD file inside .git point to?
AThe current branch or commit
BThe remote repository URL
CThe list of ignored files
DThe commit logs
Where does Git store branch and tag references?
Arefs
Bobjects
Chooks
Dinfo
Which file inside .git contains repository-specific settings?
Adescription
Bconfig
Cindex
DHEAD
What is the main purpose of the .git directory?
ATo store project source code
BTo store user documents
CTo store temporary files for the OS
DTo store all Git data and metadata for the repository
Explain the main components inside the .git directory and their roles.
Think about what Git needs to track commits, branches, and settings.
You got /4 concepts.
    Describe how Git uses the HEAD file and why it is important.
    Consider what happens when you switch branches or make commits.
    You got /3 concepts.