Terminal UI Design System

For all bash scripts used within the ColivingLiguria infrastructure (e.g., sync scripts, backend startup scripts, deployment automation), a strict and elegant Terminal UI standard must be maintained. Validating this aesthetic is just as important as the code functionality.

Core Principles

  1. Desaturated Elegance: The terminal should evoke the same feelings as the brand: understated, premium, and structured. Do not use standard harsh terminal colors (like vibrant pure red or pure green).
  2. 256-Color Support: Always enforce export TERM=xterm-256color at the beginning of the scripts to access the custom palette.
  3. Structured Verbosity: Silence internal commands (> /dev/null 2>&1) unless an error occurs. Output should be heavily curated.

The Standard Palette & Variables

Insert the following block at the beginning of any ColivingLiguria utility script:

# ============================================
# UI CONFIGURATION & HELPER FUNCTIONS
# ============================================
export TERM=xterm-256color
 
# ColivingLiguria Brand Colors (256-color)
BOLD='\033[1m'
RESET='\033[0m'
 
# Aesthetic Palette (Desaturated, Elegant)
PRIMARY='\033[38;5;180m'    # Desaturated Beige / Gold
SECONDARY='\033[38;5;109m'  # Soft Blue/Grey
SUCCESS='\033[38;5;108m'    # Sage Green
WARNING='\033[38;5;179m'    # Soft Gold/Orange
ERROR='\033[38;5;131m'      # Muted Red
MUTED='\033[38;5;246m'      # Gray
 
# Icons
ICON_GEAR="⚙️"
ICON_CHECK="✅"
ICON_ERROR="❌"
ICON_SYNC="🔄"
ICON_CLOUD="☁️"
ICON_ROCKET="🚀"
ICON_DB="🗄️"
ICON_DOC="📄"
ICON_LOCK="🔒"

Helper Functions

To standardize the output formatting, always use these helper functions instead of raw echo:

# Helper: Print Section Header
print_header() {
    echo -e "\n${SECONDARY}━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━${RESET}"
    echo -e "${BOLD}${PRIMARY}  $1${RESET}"
    echo -e "${SECONDARY}━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━${RESET}\n"
}
 
# Helper: Print Step
print_step() {
    echo -e "${BOLD}${PRIMARY}[$1]${RESET} ${BOLD}$2${RESET}..."
}
 
# Helper: Print Success
print_success() {
    echo -e "   ${SUCCESS}${ICON_CHECK} $1${RESET}"
}
 
# Helper: Print Warning
print_warning() {
    echo -e "   ${WARNING}⚠️  $1${RESET}"
}
 
# Helper: Print Error
print_error() {
    echo -e "   ${ERROR}${ICON_ERROR} $1${RESET}"
}

ASCII Header

The standard entry point should feature the ColivingLiguria typographic logo (standard figlet standard font, with backslashes properly escaped):

clear
echo -e "${BOLD}${PRIMARY}"
echo "   ____      _ _       _             _    _                  _         "
echo "  / ___|___ | (_)_   _(_)_ __   __ _| |  (_) __ _ _   _ _ __(_) __ _   "
echo " | |   / _ \| | \ \ / / | '_ \ / _\` | |  | |/ _\` | | | | '__| |/ _\` |  "
echo " | |__| (_) | | |\ V /| | | | | (_| | |__| | (_| | |_| | |  | | (_| |  "
echo "  \____\___/|_|_| \_/ |_|_| |_|\__, |____|_|\__, |\__,_|_|  |_|\__,_|  "
echo "                               |___/        |___/                      "
echo -e "                       S.r.l. - Startup Innovativa"
echo -e "${RESET}"
echo -e "${BOLD}Script Name or Utility Subtitle${RESET}"
echo -e "Started at: $(date '+%H:%M:%S')\n"