-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathnotes.sh
More file actions
80 lines (54 loc) · 1.63 KB
/
Copy pathnotes.sh
File metadata and controls
80 lines (54 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
#!/bin/bash
# Initialiser un nouveau dépôt Git
git init
# Ajouter des fichiers suivis par Git
git add <fichier>
# Confirmer les modifications avec un message
git commit -m "message du commit"
# Afficher l'état des fichiers (modifiés, ajoutés, supprimés)
git status
# Afficher l'historique des commits
git log
# Créer une nouvelle branche
git branch <nom_de_la_branche>
# Passer à une autre branche
git checkout <nom_de_la_branche>
# Fusionner une branche dans la branche courante
git merge <nom_de_la_branche>
# Cloner un dépôt distant
git clone <url_du_depot>
# Pousser les modifications vers le dépôt distant
git push origin <nom_de_la_branche>
# Récupérer les dernières modifications du dépôt distant
git pull
# Afficher les différences entre les fichiers
git diff
# Renommer une branche
git branch -m <nouveau_nom>
# Supprimer une branche locale
git branch -d <nom_de_la_branche>
# Réinitialiser le HEAD à un commit précédent
git reset --hard <commit>
# Annuler le dernier commit tout en gardant les modifications
git reset --soft HEAD~1
# Voir les branches locales et distantes
git branch -a
# Ajouter un dépôt distant
git remote add origin <url_du_depot>
# Voir les dépôts distants
git remote -v
# Supprimer un fichier suivi par Git
git rm <fichier>
# Stasher les changements locaux
git stash
# Récupérer les changements stashed
git stash pop
# Modifier le dernier commit (sans changer son hash)
git commit --amend --no-edit
# Creer un tag
git tag -a <nom du tag> -m "commentaire"
git push origin --tags
-------------------------------------------
# Github Action
- jobs: serie de steps
- steps: serie de taches