From c041fc42682d84928e3b98810c3f3be7699abe5b Mon Sep 17 00:00:00 2001 From: kprkpr Date: Mon, 13 Jun 2016 00:05:47 +0200 Subject: [PATCH] odiwhan --- jka-toolkit/odiwhan | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100755 jka-toolkit/odiwhan diff --git a/jka-toolkit/odiwhan b/jka-toolkit/odiwhan new file mode 100755 index 0000000..6e19035 --- /dev/null +++ b/jka-toolkit/odiwhan @@ -0,0 +1,21 @@ +#!/bin/bash +gitopt=`dialog --stdout --nocancel --scrollbar --menu "Odiwhan, git simple" 0 0 6 1 "Descargar actualizaciones del git (Hacer pull)" 2 "Subir actualizaciones al git (Hacer push)" 3 "Descargar un nuevo git (Hacer clone)" 4 "Cambiar de branch/rama (Hacer checkout)"` + +case $gitopt in + 1) git pull;; + 2) commit=`dialog --stdout --inputbox "Cambios (texto commit)" 10 50` + if [[ -z $commit ]];then + commit="changes" + fi + git add . && git commit -m "$commit" && git push + ;; + 3) + giturl=`dialog --stdout --inputbox "URL del git" 10 60` + git clone $giturl + ;; + 4) + gitbranch=`dialog --stdout --inputbox "Nueva rama/branch" 10 60` + git checkout $gitbranch + ;; + +esac \ No newline at end of file