||This page or section is an undeveloped draft or outline.
You can help to develop the work, or you can ask for assistance in the project room.
Naked git structure
The following is an freshly initialized git v220.127.116.11 repository.
. └── .git/ ├── HEAD ├── branches/ ├── config ├── description ├── hooks/ │ ├── applypatch-ms │ ├── commit-msg │ ├── post-commit │ ├── post-receive │ ├── post-update │ ├── pre-applypatc │ ├── pre-commit │ ├── pre-rebase │ └── update ├── info/ │ └── exclude ├── objects/ │ ├── info/ │ └── pack/ └── refs/ ├── heads/ └── tags/
HEAD indicates the currently checked out code. This will usually point to the branch you're currently working on.
You can also enter what git calls a "detached HEAD" state, where you are not on a local branch. In this state the HEAD points directly to a commit rather than a branch.
The configuration file for this git repository. It can contain settings for how to manage and store data in the local repository, remote repositories it knows about, information about the local user and other configuration data for git itself.
Used by repository browser tools - contains a description of what this project is. Not normally changed in non-shared repositories.
Contains scripts to be run when particular events happen within the git repository.
Hooks would be used, for example, to run tests before creating each commit, filter uploaded content, and implement other such custom requirements.
This is where all the files, directory listings, commits and such are stored.
There are both unpacked objects in numbered directories under this, and "packs" containing many compressed objects within a pack directory. The uncompressed objects will periodically be collected together by automatic "git gc" runs in to packs.
This contains the information about which branches point where. It normally contains a "heads" directory for your local branches and a "remotes" directory for your copies of remote branches. Not all branches are within these directories - branches which have not changed recently may be found in the file .git/packed-refs .
- ^ Generated with tree v18.104.22.168 using