Refactor wecker.sh script for better readability and functionality
- Updated comments for better clarity and documentation - Introduced a DEBUG variable to toggle debugging information - Utilized set -e to stop the script on errors for better error handling - Corrected the script flow to ensure proper execution of color changes - Introduced a new ssh_command function for executing SSH commands - Improved check_ip function for finding the IP address more reliably - Added DEBUG checks to bypass certain functions for debugging purposes - Fixed issues with sleep intervals during script execution - Improved logging by adding echo statements for important steps - Adjusted variable names for better readability - Removed unnecessary comments and debug statements - Added set -e for better error handling - Introduced command-line option -d for enabling DEBUG mode - Improved formatting and indentation for better code readability
This commit is contained in:
parent
3d2605a8f8
commit
5ecd10a431