Files
loki/scripts/control-states.generated.sh
T
65dea6f303 chore: pnpm — the fleet has one package manager (#478)
* chore: pnpm — the fleet has one package manager

- packageManager pnpm@11.25.0; lockfile via pnpm import, package-lock.json
  removed; npm "workspaces" replaced by pnpm-workspace.yaml packages
  (packages/agent), and bridge/ joins the workspace — one install, one
  lockfile, its own package-lock.json removed
- npm "overrides" (fast-uri pin) moved to pnpm-workspace.yaml (pnpm ignores
  the npm-only field)
- allowBuilds: better-sqlite3, node-pty, @sentry/cli, native toolchain, and
  the two git-hosted deps (@fleet/ai-forms, limitkit — pnpm wants the exact
  resolved spec, keys move with the pinned tags); temporary
  minimumReleaseAgeExclude for our own @bitbaum/ai-kit@0.6.2
- phantom deps declared: @auth/core (src/auth.ts augments @auth/core/jwt —
  TS2664 under pnpm's strict layout), dotenv, sharp (scripts)
- CI/audit/deploy workflows: pnpm/action-setup@v6, store-dir pinned outside
  the action's bin dir, cache: pnpm, frozen-lockfile; deploy's separate
  `npm --prefix bridge ci` is covered by the workspace install; Next cache
  key hashes pnpm-lock.yaml; npm audit → pnpm audit
- desktop-release: root install → pnpm; desktop/ itself STAYS an npm package
  (own package-lock.json, electron toolchain untouched)
- husky: pre-push staleness gate now compares pnpm-lock.yaml against
  node_modules/.modules.yaml; hooks + scripts (deploy-hetzner, hetzner/deploy,
  install-app, doctor, smoke) converted to pnpm
- check-deploy-ready fleet gate now recognizes pnpm verify/test lines too

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WqKqMnHQHSmkGFfc5t7Rxn

* fix: prettier-format pnpm-workspace.yaml — format:check gates verify

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01WqKqMnHQHSmkGFfc5t7Rxn

---------

Co-authored-by: Mao Nakamoto <41178744+maonakamoto@users.noreply.github.com>
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-09-04 10:35:27 +00:00

66 lines
3.0 KiB
Bash

#!/usr/bin/env bash
# GENERATED FILE — DO NOT EDIT BY HAND.
# Source of truth: src/lib/control-states.ts (STATE_DEFINITIONS).
# Regenerate: npx tsx scripts/generate-bash-state-vocab.ts
#
# Variables exposed:
# FC_STATE_KEYS — space-separated list of all state keys
# FC_LABEL_<KEY> — short human label (badge text)
# FC_DESCRIPTION_<KEY> — one-line WHY this state is true
# FC_COUNTER_CATEGORY_<KEY> — chip bucket: working|waiting|idle|offline
#
# Usage from bash:
# source "$(dirname "$0")/control-states.generated.sh"
# echo "$FC_LABEL_OFFLINE" # → "Offline"
# echo "$FC_DESCRIPTION_OPEN_IDLE" # → "Agent process detected …"
FC_STATE_KEYS='offline not_running recently_active tab_open open_idle working ready orchestration_ready closing completed'
FC_LABEL_OFFLINE='Offline'
FC_DESCRIPTION_OFFLINE='The builder hasn'\''t pushed fresh state for this project — we don'\''t know what'\''s happening right now.'
FC_COUNTER_CATEGORY_OFFLINE='offline'
FC_LABEL_NOT_RUNNING='Not running'
FC_DESCRIPTION_NOT_RUNNING='No agent process and no terminal tab detected for this project.'
FC_COUNTER_CATEGORY_NOT_RUNNING='idle'
FC_LABEL_RECENTLY_ACTIVE='Active recently'
FC_DESCRIPTION_RECENTLY_ACTIVE='No live agent process is visible to FleetCrown, but a dispatch or run landed for this project recently — work likely happened in a terminal FleetCrown can'\''t observe.'
FC_COUNTER_CATEGORY_RECENTLY_ACTIVE='idle'
FC_LABEL_TAB_OPEN='Tab open'
FC_DESCRIPTION_TAB_OPEN='Terminal workspace exists for this project but no agent process is running in it.'
FC_COUNTER_CATEGORY_TAB_OPEN='idle'
FC_LABEL_OPEN_IDLE='Awaiting input'
FC_DESCRIPTION_OPEN_IDLE='Agent process detected but no recent lifecycle signal — the agent is at the prompt waiting for your next message.'
FC_COUNTER_CATEGORY_OPEN_IDLE='waiting'
FC_LABEL_WORKING='Working'
FC_DESCRIPTION_WORKING='Agent is mid-turn — actively reading files, calling tools, or writing.'
FC_COUNTER_CATEGORY_WORKING='working'
FC_LABEL_READY='Ready for next step'
FC_DESCRIPTION_READY='Stop hook fired recently — the agent finished a turn and is ready for the next instruction. The handoff lists the suggested next move.'
FC_COUNTER_CATEGORY_READY='waiting'
FC_LABEL_ORCHESTRATION_READY='Ready for next step'
FC_DESCRIPTION_ORCHESTRATION_READY='Latest orchestration run completed and produced a result. Pick the next intent or accept the suggested next-best.'
FC_COUNTER_CATEGORY_ORCHESTRATION_READY='waiting'
FC_LABEL_CLOSING='Closing'
FC_DESCRIPTION_CLOSING='Closing hook fired — the agent process is shutting down.'
FC_COUNTER_CATEGORY_CLOSING='idle'
FC_LABEL_COMPLETED='Completed'
FC_DESCRIPTION_COMPLETED='Closed hook fired — the agent exited cleanly.'
FC_COUNTER_CATEGORY_COMPLETED='idle'
# Returns 0 if the generated file looks structurally sane,
# 1 if the FC_STATE_KEYS variable is missing or empty.
fc_state_vocab_sanity_check() {
[ -n "${FC_STATE_KEYS:-}" ] || return 1
return 0
}