File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -88,17 +88,23 @@ if [ $# -eq 2 ]; then
8888 printf -- ' \033[32m [Git Commit]: [FINISHED] without errors. \033[0m\n'
8989else
9090 GIT_COMMIT_MSG=" [Git Commit]: at $( date --rfc-3339=seconds) "
91- echo " [Git Message]: ${GIT_COMMIT_MSG} "
92- git commit -m " ${GIT_COMMIT_MSG} " || printf -- ' \033[31m [EXIT] with status code %s.\033[0m\n' ${ERROR_CODE:- 1} || exit 1
91+ echo " [Auto]: Setting GIT_COMMIT_MSG to ${GIT_COMMIT_MSG} "
9392 printf -- ' \033[32m [Git Commit]: [FINISHED] without errors. \033[0m\n'
9493fi
9594
9695if [ -d " ${GIT_LOCAL_PATH} " ]; then
9796 cd " ${GIT_LOCAL_PATH} " || echo " Current Dir: $PWD " || exit 2
9897 printf -- ' \033[32m [SUCCESS]: %s \033[0m\n' " ${GIT_LOCAL_PATH} "
99- git add . || echo || exit 1
98+
99+ # ## Setup for commit.
100+ git add . || echo || exit 1
100101 printf -- ' \033[32m [SUCCESS]: git add . \033[0m\n'
101- # ## Push and build the repository
102+
103+ # ## Commit changes.
104+ git commit -m " ${GIT_COMMIT_MSG} " || printf -- ' \033[31m [EXIT] with status code %s.\033[0m\n' ${ERROR_CODE:- 1} || exit 1
105+ printf -- ' \033[32m [SUCCESS]: git commit -m \033[0m\n'
106+
107+ # ## Push code to Repository
102108 git push origin master || printf -- ' \033[31m [EXIT] with status code %s.\033[0m\n' ${ERROR_CODE:- 1} || exit 1
103- printf -- ' \033[32m [SUCCESS]: git push origin master \033[0m\n'
109+ printf -- ' \033[32m [SUCCESS]: git push origin master \033[0m\n'
104110fi
You can’t perform that action at this time.
0 commit comments