ctdo/Vorträge/git/first_steps/2_git_dir.md

1.7 KiB

!SLIDE

der .git Ordner

!SLIDE command smallest

$ tree .git
.git
├── branches
├── config
├── description
├── HEAD
├── hooks
│   └── [...]
├── info
│   └── exclude
├── objects
│   ├── info
│   └── pack
└── refs
    ├── heads
    └── tags

!SLIDE center

config

  • /etc/gitconfig
  • ~/.gitconfig
  • .git/config

!SLIDE command small

$ cat ~/.gitconfig
[user]
    email = badboy@ctdo.de
    name = Jan-Erik Rediger
[alias]
    cia = commit -am
    lol = log --oneline --graph --decorate

!SLIDE command smallest

$ tree .git
.git
├── branches
├── config
├── description
├── HEAD
├── hooks
│   └── [...]
├── info
│   └── exclude
├── objects
│   ├── info
│   └── pack
└── refs
    ├── heads
    └── tags

!SLIDE bullets incremental

objects

  • die (gepackten) Dateien & Daten
  • benannt nach der SHA1
    • 32/09658ac8d80bc9726d3a33d77e3dfc5fe6035e

!SLIDE command smallest

$ tree .git
.git
├── branches
├── config
├── description
├── HEAD
├── hooks
│   └── [...]
├── info
│   └── exclude
├── objects
│   ├── info
│   └── pack
└── refs
    ├── heads
    └── tags

!SLIDE bullets incremental

refs

  • Zeiger auf verschiedene Revisionen
    • head/master
    • tags/v0.0.1
    • remotes/origin/HEAD
  • einzelne Dateien enthalten wieder nur den SHA1-Hash