feat: rebrand as Hermit — TUI palette, dual glyphs, binary 0.10.0
Ship hermit binary (cst-agent symlink), ~/.config/hermit with legacy fallback, Hermit color theme and mini crab frames, plus SVG→PUA font build pipeline. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
+19
-12
@@ -44,7 +44,9 @@ run_make() {
|
||||
install_bin() {
|
||||
local prefix="$1" bin="$2"
|
||||
mkdir -p "$prefix/bin"
|
||||
install -m 0755 "$bin" "$prefix/bin/cst-agent"
|
||||
install -m 0755 "$bin" "$prefix/bin/hermit"
|
||||
ln -sfr "$prefix/bin/hermit" "$prefix/bin/cst-agent" 2>/dev/null || \
|
||||
ln -sf hermit "$prefix/bin/cst-agent"
|
||||
}
|
||||
|
||||
install_helpers() {
|
||||
@@ -60,7 +62,7 @@ EOF
|
||||
#!$(command -v bash)
|
||||
# Manage the parliament seat service (foreground under systemd, or --service).
|
||||
set -euo pipefail
|
||||
BIN="$prefix/bin/cst-agent"
|
||||
BIN="$prefix/bin/hermit"
|
||||
cmd="\${1:-status}"
|
||||
case "\$cmd" in
|
||||
status)
|
||||
@@ -102,19 +104,24 @@ install_from_release() {
|
||||
if [[ -z "$ver" ]]; then
|
||||
ver="$(cst_version)"
|
||||
fi
|
||||
local name="cst-agent-$ver-linux-$arch.tar.gz"
|
||||
local name="hermit-$ver-linux-$arch.tar.gz"
|
||||
# One-cycle legacy asset name fallback handled below if download fails.
|
||||
local tmp
|
||||
tmp="$(mktemp -d /tmp/cst-rel.XXXXXX)"
|
||||
# shellcheck disable=SC2046
|
||||
local legacy="cst-agent-$ver-linux-$arch.tar.gz"
|
||||
if ! cst_fetch "$tmp/$name" $(cst_release_asset_urls "$ver" "$name"); then
|
||||
echo "release download failed for $name; falling back to source build" >&2
|
||||
rm -rf "$tmp"
|
||||
return 1
|
||||
if ! cst_fetch "$tmp/$legacy" $(cst_release_asset_urls "$ver" "$legacy"); then
|
||||
echo "release download failed; falling back to source build" >&2
|
||||
rm -rf "$tmp"
|
||||
return 1
|
||||
fi
|
||||
name="$legacy"
|
||||
fi
|
||||
tar -C "$tmp" -xzf "$tmp/$name"
|
||||
local bin
|
||||
bin="$(find "$tmp" -type f -name cst-agent | head -1)"
|
||||
[[ -x "$bin" ]] || { echo "tarball missing cst-agent" >&2; rm -rf "$tmp"; return 1; }
|
||||
bin="$(find "$tmp" -type f \( -name hermit -o -name cst-agent \) | head -1)"
|
||||
[[ -x "$bin" ]] || { echo "tarball missing hermit/cst-agent" >&2; rm -rf "$tmp"; return 1; }
|
||||
install_bin "$prefix" "$bin"
|
||||
rm -rf "$tmp"
|
||||
echo "==> installed release $ver ($arch) -> $prefix/bin/cst-agent"
|
||||
@@ -177,7 +184,7 @@ main() {
|
||||
if install_from_release "$prefix" "$dir"; then
|
||||
install_helpers "$prefix" "$dir"
|
||||
echo
|
||||
echo "OK: $("$prefix/bin/cst-agent" --version) (release install)"
|
||||
echo "OK: $("$prefix/bin/hermit" --version) (release install)"
|
||||
case ":$PATH:" in
|
||||
*":$prefix/bin:"*) ;;
|
||||
*) echo "Add to PATH: export PATH=\"$prefix/bin:\$PATH\"" ;;
|
||||
@@ -209,14 +216,14 @@ main() {
|
||||
install_helpers "$prefix" "$dir"
|
||||
|
||||
echo
|
||||
echo "OK: $("$prefix/bin/cst-agent" --version)"
|
||||
echo "OK: $("$prefix/bin/hermit" --version)"
|
||||
case ":$PATH:" in
|
||||
*":$prefix/bin:"*) ;;
|
||||
*) echo "Add to PATH: export PATH=\"$prefix/bin:\$PATH\"" ;;
|
||||
esac
|
||||
echo "Run 'cst-agent' inside a project directory; upgrade with 'cst-agent-update'."
|
||||
echo "Run 'hermit' (or 'cst-agent') in a project; upgrade with 'cst-agent-update'."
|
||||
echo "Fast upgrade from Release: 'cst-agent-update --release'."
|
||||
echo "Parliament seat service helper: 'cst-agent-service status|install-unit'."
|
||||
echo "Parliament helper: 'cst-agent-service status|install-unit'."
|
||||
echo "The first start asks for the provider and its API key and saves them."
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user