diff --git a/ecran b/ecran index a53b27b..9f3f68b 100755 --- a/ecran +++ b/ecran @@ -3,9 +3,32 @@ # Description: Manage video output (size, orientation, ...) # And reload wm configuration -# First and main screen (laptop screen,…) -MAIN_SCREEN="LVDS-1" +# Vars {{{ +## First and main screen (laptop screen,…) +readonly MAIN_SCREEN="LVDS-1" +[ -z "${DEBUG}" ] && readonly DEBUG=0 + +## Colors +readonly PURPLE='\033[1;35m' +readonly RED='\033[0;31m' +readonly RESET='\033[0m' +readonly COLOR_DEBUG="${PURPLE}" +# }}} + +# Functions {{{ +debug_message() { # {{{ + + local_message="${1}" + + ## Print message if DEBUG is enable (=0) + [ "${DEBUG}" -eq "0" ] && printf '\e[1;35m%-6b\e[m\n' "DEBUG − ${PROGNAME}: ${local_message}" + + return 0 +} +# }}} + +# }}} case "${1}" in ds | dockstation | work )