From 216c096c3782e2d32bc4c842ee76bbd611577891 Mon Sep 17 00:00:00 2001 From: _N3m0 Date: Mon, 6 Mar 2023 17:33:33 +0100 Subject: [PATCH] ajout gestion commit des cheat-sheet --- cs | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/cs b/cs index 57d4465..f646b9e 100755 --- a/cs +++ b/cs @@ -11,11 +11,25 @@ if [[ $1 = "-ln" ]]; then ln -s ~/dev/cheat-sheet/$2 $3 exit fi +if [[ $1 = "-st" ]]; then + cd ~/dev/cheat-sheet + git status + exit +fi +if [[ $1 = "-ci" ]]; then + echo "commit avec -m : \"$2\"" + cd ~/dev/cheat-sheet + git add . + git commit -am "$2" + exit +fi if [[ $1 = "-h" ]]; then - echo "cs -h : affiche commande" + echo "cs -h : affiche aide commande" echo "cs : ouvre le cheat-sheet ou le crée s'il n'exite pas" echo "cs -l : affiche liste cheat sheet" echo "cs -ln : crée un lien symbolique du cheat-sheet nommé lien" + echo "cs -st : affiche le status git des cheat-sheet (eq: cd ~/dev/cheat-sheet && git status)" + echo "cs -ci \"message\" : commit les cheat-sheet (eq: cd ~/dev/cheat-sheet && git add . && git commit -am \"message\")" exit fi