Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| it:git [2025/11/02 08:44] – vlp | it:git [2026/08/31 08:00] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | ## Stash | + | ====== Git ====== |
| - | i.e. : éviter de laisser | + | ===== Réécrire |
| + | <code bash> | ||
| + | git rebase -i < | ||
| + | git push --force-with-lease | ||
| + | </ | ||
| - | **tig permet une visualisation plus esthetic de git show** | + | Utiliser `--force-with-lease` plutôt que `--force` pour éviter d' |
| - | | + | ===== Signer les commits ===== |
| - | git push --force | + | <code bash> |
| - | + | git config user.signingkey vlp@fdn.fr | |
| - | ## Sign commit | + | git commit |
| + | git config | ||
| + | </ | ||
| + | |||
| + | ===== Ajouter un second dépôt distant ===== | ||
| + | <code bash> | ||
| + | git remote add second_repo git@git_provider.com: | ||
| + | git remote set-url --add --push origin git@git_provider.com: | ||
| + | </ | ||
| - | git config user.signingkey vlp@fdn.fr | ||
| - | git commit -S -m " | ||
| - | git config --global commit.gpgsign true // alway sign | ||
| - | | ||
| - | ## add second repo | ||
| - | git remote add second_repo git@git_provider.com: | ||
| - | git remote set-url --add --push origin git@git_provider.com: | ||
