Skip to content

unix_scm

Andrea Paolini edited this page Jan 2, 2021 · 1 revision

Software Configuration Management

Or Source Code Management, or Versioning, or SCM...

git cheatsheet

See also:

Create a project

git init
git add .
git commit

Committing

git diff --cached
git add <stuff> ; git commit   # or git commit -a

Show the status

git log
git log --stat --summary

Branching

git branch experimental     # create
git branch                  # Show all the branches
git checkout experimental   # Switch to branch

Merging

git merge experimental      # Merge FROM ...

Pull from upstream "incorporating" the changes:

git pull --rebase

Graphical interface

  • git-gui
  • gitk
  • gitg

Quickly one-off share a git repository (cfr CentOS):

# Server side
sudo yum install git-daemon
firewall-cmd --add-port=9418/tcp
git daemon --verbose --export-all --base-path=.git --reuseaddr --strict-paths .git/
# Client side
git clone git://remote.example.net/

Clone this wiki locally