🔧 chore(scripts/sync-config): use utils script functions
This commit is contained in:
@@ -30,7 +30,6 @@ Update_local() {
|
|||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
Check_current_dir
|
|
||||||
Print_header
|
Print_header
|
||||||
|
|
||||||
printf "\n"
|
printf "\n"
|
||||||
@@ -39,13 +38,12 @@ echo "This script is intended to be used only by the repository owner"
|
|||||||
printf "\n"
|
printf "\n"
|
||||||
|
|
||||||
echo "Please run this script in it's current directory to avoid issues"
|
echo "Please run this script in it's current directory to avoid issues"
|
||||||
echo "Tip: Press ^C([Ctrl] + [C]) to stop script at any time"
|
echo "Tip: Press [Ctrl] + [C] to stop script at any time"
|
||||||
|
|
||||||
printf "\n"
|
printf "\n"
|
||||||
|
|
||||||
echo -n "Update local repository with host configurations? [y/n] "
|
Ask "Update local repository with host configurations?"
|
||||||
read answer
|
if [[ ! $answer == y ]]; then
|
||||||
if ! [[ $answer =~ y ]]; then
|
|
||||||
Send_log "Exiting"
|
Send_log "Exiting"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
@@ -55,7 +53,7 @@ printf "\n"
|
|||||||
Clean_local
|
Clean_local
|
||||||
Update_local
|
Update_local
|
||||||
|
|
||||||
if command -v git > /dev/null 2>&1; then
|
if command -v git > /dev/null; then
|
||||||
git status
|
git status
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user