This page is about the notion of repository and how it's implemented in Git.
The git repository is a subdirectory named .git called also GIT_DIR that contains all repository files.
It contains :
When you are working in git on the local file system (file explorer,..), you are working in the working area/tree which is by default a checkout of the head (the last commit in the current branch).
A newly-initialized .git directory typically looks like:
config
description
HEAD
hooks/
info/
objects/
refs/
where:
A bare repository 1) is an empty repository that was created on a server to be able to receive their first push.
Creation
git init --bare
Example to list the branches
git --git-dir .\subdirectory\.git branch
Strategy:
See also installing-projects-from-source
See Git - SubProject