#!/usr/bin/env bash # SPDX-License-Identifier: AGPL-3.0-only # Copyright 2026-present the Unsloth AI Inc. team. All rights reserved. See /studio/LICENSE.AGPL-3.0 set -euo pipefail SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" REPO_ROOT="$(cd "$SCRIPT_DIR/.." && pwd)" RULE=$(printf '\342\224\200%.0s' {1..52}) # ── Maintainer-editable defaults ────────────────────────────────────────── # Change these in the GitHub-hosted script so all users get updated defaults. # User environment variables always override these baked-in values. # # _DEFAULT_LLAMA_PR_FORCE : PR number to build by default ("" = normal path) # _DEFAULT_LLAMA_SOURCE : git clone URL for source builds # _DEFAULT_LLAMA_TAG : llama.cpp ref to build ("latest" = newest release, # "master" = bleeding-edge, "bNNNN" = specific tag) # ────────────────────────────────────────────────────────────────────────── _DEFAULT_LLAMA_PR_FORCE="" _DEFAULT_LLAMA_SOURCE="https://github.com/ggml-org/llama.cpp" _DEFAULT_LLAMA_TAG="latest" # ── Colors (same palette as startup_banner / install_python_stack) ── if [ -n "${NO_COLOR:-}" ]; then C_TITLE= C_DIM= C_OK= C_WARN= C_ERR= C_RST= elif [ -t 1 ] || [ -n "${FORCE_COLOR:-}" ]; then C_TITLE=$'\033[38;5;150m' C_DIM=$'\033[38;5;245m' C_OK=$'\033[38;5;108m' C_WARN=$'\033[38;5;136m' C_ERR=$'\033[91m' C_RST=$'\033[0m' else C_TITLE= C_DIM= C_OK= C_WARN= C_ERR= C_RST= fi # ── Output helpers ── # Consistent column layout: 2-space indent, 15-char label (fits llama-quantize), then value. # Usage: step