From fb2ae3872314acb2f1ab15cad3bfaae671a09a98 Mon Sep 17 00:00:00 2001 From: Michael Stanclift Date: Fri, 17 Jul 2020 09:45:08 -0500 Subject: [PATCH] 2.1.7 (#70) * import config file before executing * show_target function * git Co-authored-by: Michael Stanclift --- CHANGELOG.md | 4 ++++ gravity-sync.sh | 43 +++++++++++++++++++++++++++++-------------- 2 files changed, 33 insertions(+), 14 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 405ebe8..cf1f2ed 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -41,6 +41,10 @@ Skipping a few digits because what does it really matter? (Thanks to [@fbourqui](https://github.com/fbourqui) for this contributions to this release.) +#### 2.1.7 +- Adjusts placement of configuration import to fully implement `ROOT_CHECK_AVOID` variable. +- Someday I'll understand all these git error messages. + ## 2.0 ### The Smart Release diff --git a/gravity-sync.sh b/gravity-sync.sh index bace2f8..435788e 100755 --- a/gravity-sync.sh +++ b/gravity-sync.sh @@ -86,10 +86,10 @@ function import_gs { source $HOME/${LOCAL_FOLDR}/${CONFIG_FILE} error_validate - MESSAGE="Targeting ${REMOTE_USER}@${REMOTE_HOST}" - echo_info + # MESSAGE="Targeting ${REMOTE_USER}@${REMOTE_HOST}" + # echo_info - detect_ssh + # detect_ssh else echo_fail @@ -101,6 +101,13 @@ function import_gs { fi } +function show_target { + MESSAGE="Targeting ${REMOTE_USER}@${REMOTE_HOST}" + echo_info + + detect_ssh +} + # GS Update Functions ## Master Branch function update_gs { @@ -771,7 +778,7 @@ function logs_export { ### Output Sync Logs function logs_gs { - import_gs + # import_gs MESSAGE="Tailing ${LOG_PATH}/${SYNCING_LOG}" echo_info @@ -795,7 +802,7 @@ function logs_gs { ## Crontab Logs ### Core Crontab Logs function show_crontab { - import_gs + # import_gs MESSAGE="Replaying Last Cronjob" echo_stat @@ -1611,7 +1618,7 @@ function task_automate { MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs CRON_EXIST='0' CRON_CHECK=$(crontab -l | grep -q "${GS_FILENAME}" && echo '1' || echo '0') @@ -1832,8 +1839,8 @@ function task_compare { MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs - + # import_gs + show_target validate_gs_folders validate_ph_folders validate_os_sshpass @@ -1980,6 +1987,8 @@ function root_check { MESSAGE="${PROGRAM} ${VERSION} Executing" echo_info + import_gs + MESSAGE="Evaluating Arguments" echo_stat @@ -1995,7 +2004,8 @@ case $# in MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs + show_target validate_gs_folders validate_ph_folders validate_os_sshpass @@ -2011,7 +2021,8 @@ case $# in MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs + show_target validate_gs_folders validate_ph_folders validate_os_sshpass @@ -2025,7 +2036,8 @@ case $# in MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs + show_target validate_gs_folders validate_ph_folders validate_os_sshpass @@ -2039,7 +2051,8 @@ case $# in MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs + show_target validate_gs_folders validate_ph_folders validate_os_sshpass @@ -2053,7 +2066,8 @@ case $# in MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs + show_target validate_gs_folders validate_ph_folders validate_os_sshpass @@ -2067,7 +2081,8 @@ case $# in MESSAGE="${MESSAGE}: ${TASKTYPE} Requested" echo_good - import_gs + # import_gs + show_target validate_gs_folders validate_ph_folders