Skip to content

Instantly share code, notes, and snippets.

@pamaury
Created December 19, 2019 10:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pamaury/f916a4432cbc84adc044698f50d8a8fc to your computer and use it in GitHub Desktop.
Save pamaury/f916a4432cbc84adc044698f50d8a8fc to your computer and use it in GitHub Desktop.
Comment gérer un conflit git, du type "a merge would override your changes":
1) enregistrer les modifications locales: git stash
2) faire le merge: git pull
3) réappliquer ls modifications locales: git stash pop
4) maintenant ils y a peut-être des conflicts, git dit:
auto-merge blabla
CONFLICT blabla
5) pour chacun des fichiers avec un conflit, l'ouvrir et chercher les conflits,
c'est toujours du type:
<<<<< upstream
la version des autres
=====
ta version
>>>>> stashed
Il faut enlever les <<<<, ==== et >>>> et corriger le problème
6) une fois fait, faire pour chaque fichier avec un conflit: git add fichier
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment