projtec:git
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
projtec:git [2020/10/08 20:06] – [A Lire] orel | projtec:git [2024/03/18 15:06] (current) – external edit 127.0.0.1 | ||
---|---|---|---|
Line 451: | Line 451: | ||
L' | L' | ||
+ | |||
+ | === Suppression d'une Branche Distante ==== | ||
+ | |||
+ | Pour supprimer une branche locale sur votre ordinateur, la commande est la suivante : | ||
+ | |||
+ | $ git branch -d [nom_de_la_branche] | ||
+ | |||
+ | Ou bien : | ||
+ | |||
+ | $ git branch -D [nom_de_la_branche] | ||
+ | |||
+ | Pour supprimer la branche située sur le dépôt distant (syntaxe récente) : | ||
+ | |||
+ | $ git push origin --delete [nom_de_la_branche] | ||
+ | |||
+ | Pour mettre à jour les changements sur un autre ordinateur, il faut faire : | ||
+ | |||
+ | $ git fetch --all -prune | ||
+ | |||
+ | => https:// | ||
+ | ==== Suppression de Commit Fautifs sur le dépôt distant ==== | ||
+ | |||
+ | Revenir à l' | ||
+ | |||
+ | $ git reset --hard <commit hash> | ||
+ | |||
+ | Forcer cet état comme le dernier état du dépôt : | ||
+ | |||
+ | $ git push --force origin master | ||
+ | | ||
+ | Attention : Ces commandes sont susceptibles d' | ||
==== Savane ==== | ==== Savane ==== | ||
projtec/git.1602187616.txt.gz · Last modified: 2024/03/18 15:05 (external edit)