Memo Commandes GIT
PushGestion Commitcontenu
AddAjouter andun updatesfichier filesou dossier modifié
# Add a specific file
git add filename
# Add all changed files in current directory
git add .
CreatePour newcréer commitun nouveau commit:
# Add commit message directly in commit command
git commit -m "New commit"
# Open editor to write commit message
git commit
PushPousser les derniers commit anset filesfichiers tovers serverle serveur
push origin branch_name
# Push to "main" branch
push origin main
ManageGestions Branchdes branches
CheckLister exitingles branchbranches existante du dépôt
git branch
SwitchBasculer tosur anune existingbranche branch existante
git checkout <branch_name>
OrOn createpeut acréer newune branchnouvelle withbranche avec l'option -b optin
git checkout -b <new_branch>
Liens
https://wiki-tech.io/Cheatsheet/git