schon/scripts/Unix/starter.sh
2026-01-25 23:16:38 +03:00

36 lines
949 B
Bash

#!/usr/bin/env bash
set -euo pipefail
if [ -n "${BASH_VERSION-}" ]; then script_path="${BASH_SOURCE[0]}"
elif [ -n "${ZSH_VERSION-}" ]; then script_path="${(%):-%x}"
else script_path="$0"
fi
script_dir="$(cd "$(dirname "$script_path")" && pwd -P)"
# Load shared utilities
# shellcheck source=../lib/utils.sh
source "$script_dir/../lib/utils.sh"
if [ ! -d "./schon" ]; then
log_error "❌ Please run this script from the project's root (where the 'schon' directory lives)."
exit 1
fi
art_path="$script_dir/../ASCII_ART_SCHON"
if [ ! -f "$art_path" ]; then
log_error "❌ Could not find ASCII art at $art_path"
exit 1
fi
clear
if is_interactive; then
# In interactive mode, show colorful banner
royal_grey='\033[38;2;127;144;158m'
reset='\033[0m'
echo -e "${royal_grey}$(cat "$art_path")${reset}"
echo
else
# In non-interactive mode, show simple banner
echo "Schon by WISELESS TEAM"
fi