1 2 3 4 5
# Clear console if possible when logging out if [[ "$SHLVL" = 1 ]] && command -v clear_console &>/dev/null; then clear_console -q fi