$ git pull –rebase origin master $ git checkout -b num-branchName … dev ... $ g

$ git pull –rebase origin master $ git checkout -b num-branchName … dev ... $ git add [-A] . $ git commit -m « #num - explication » … $ git checkout master $ git pull --rebase origin master $ git checkout num-branchName $ git rebase master … $ git add [-A] . $ git commit -m « #num - explication » $ git push origin num-branchName … $ git checkout master $ git pull --rebase origin master $ git checkout num-branchName $ git rebase master $ git checkout master $ git merge –no-ff num-branchName $ git push origin master $ git branch -D num-branchName $ git push origin :num-branchName Cmd Explication $ git pull –rebase origin master Mettre à jour la branche master $ git checkout -b num-branchName Créer ma branche $ git add [-A] . J'ajoute mes modifs (-A pour toutes) $ git commit -m « #num - explication » Je valide mes modifs $ git checkout master Revenir sur master $ git pull --rebase origin master Mettre à jour master $ git checkout num-branchName Revenir sur ma branche $ git rebase master Rajouter les commits de master dans ma branch $ git push origin num-branchName Si besoin je pousse ma branche sur origine (week-end ou vacances) $ git merge –no-ff num-branchName Je merge mes commits dans master avec un commit de merge obligatoire $ git push origin master Je pousse mes modifs $ git branch -D num-branchName Je supprime ma branche locale $ git push origin :num-branchName Je supprime ma branche distante (si besoin) Je commence un nouveau dev Très souvent Week-end, vacances ou par sécurité le soir Au moins une fois par jour J'ai fini mon dev ! Champagne ! uploads/Geographie/ liste-des-commande-git.pdf

  • 25
  • 0
  • 0
Afficher les détails des licences
Licence et utilisation
Gratuit pour un usage personnel Attribution requise
Partager