Git

Git Scorciatoie

Riferimento ai comandi della CLI di Git per il controllo di versione — staging, commit, branch e operazioni remote.

Source: Documentazione ufficiale · Aggiornato 2026-06

Scorciatoie
5
Categorie

Guida al cheat sheet

Git shortcuts worth learning first

Questa pagina raccoglie 32 scorciatoie da tastiera cercabili per Git in 5 categorie. Parti dalle categorie principali, poi stampa il cheat sheet quando vuoi tenerlo a portata di mano.

  • git initgitinit
  • git statusgitstatus
  • git branch (list)gitbranch
  • git remote -v (list remotes)gitremote-v
  • git loggitlog
  • git clone <url>gitclone<url>

Configurazione e init

4 scorciatoie
git init
gitinit
git clone <url>
gitclone<url>
git config --global user.name
gitconfig--globaluser.name
git config --global user.email
gitconfig--globaluser.email

Staging e commit

8 scorciatoie
git status
gitstatus
git add <file>
gitadd<file>
git add . (stage all)
gitadd.
git commit -m "msg"
gitcommit-m"msg"
git commit --amend
gitcommit--amend
git reset HEAD <file> (unstage)
gitresetHEAD<file>
git diff (unstaged changes)
gitdiff
git diff --staged
gitdiff--staged

Branch

7 scorciatoie
git branch (list)
gitbranch
git branch <name> (create)
gitbranch<name>
git checkout <branch>
gitcheckout<branch>
git checkout -b <branch> (create+switch)
gitcheckout-b<branch>
git merge <branch>
gitmerge<branch>
git branch -d <branch> (delete)
gitbranch-d<branch>
git rebase <branch>
gitrebase<branch>

Remoto

6 scorciatoie
git remote -v (list remotes)
gitremote-v
git fetch
gitfetch
git pull
gitpull
git push
gitpush
git push -u origin <branch>
gitpush-uorigin<branch>
git push --force-with-lease
gitpush--force-with-lease

Log e cronologia

7 scorciatoie
git log
gitlog
git log --oneline
gitlog--oneline
git log --graph --oneline
gitlog--graph--oneline
git show <commit>
gitshow<commit>
git stash
gitstash
git stash pop
gitstashpop
git reset --hard HEAD
gitreset--hardHEAD

Domande frequenti

Qual è il modo più veloce per trovare le scorciatoie di Git su questa pagina?

Usa la barra di ricerca o premi /, poi digita un'azione come git init.

Posso stampare questo cheat sheet di scorciatoie di Git?

Sì. Usa il pulsante Stampa / PDF o il comando stampa del browser per salvare un cheat sheet compatto.

Questa pagina include le scorciatoie Windows e Mac per Git?

Sì. Usa le schede OS per passare tra scorciatoie Windows e macOS. Ad esempio, git init è git init su Windows e git init su macOS dove disponibile.

Vedi anche

Nessuna scorciatoia corrisponde alla ricerca.