Pcornel
Linux · Software & Source

Git

Cheat sheet · https://pcornel.dk/topic.php?topic=2906

Back to the Topic

Answer

Git is the distributed version control system: repositories with commits, branches and remotes; used for code, configuration and infrastructure-as-code.

Remember

Commit small, meaningful changes. git status and git diff before committing. Never commit secrets — if you did, rotate them. Use branches and pull requests for review.

First checks

  • git status / git log --oneline -5 — repository state
  • ldd <binary> — shared libraries
  • ldconfig -p | grep <lib> — libraries in the linker cache
  • make --version; gcc --version — build tools

Verify in this order

edit → stage → commit → push → review → merge

Where it usually breaks

First mismatch in persistent intent → provider/parser/generator → kernel/userspace runtime → dependency/security context → logs/counters → consumer-visible read-back; preserve identity/native diagnostic/pre-state before mutation.

Read-only verification commands unless stated otherwise. Confirm syntax for your platform and release. Full reference: https://pcornel.dk/topic.php?topic=2906

Confirmation

Confirm action

Continue?