Rust binary (server/src/bin/atlas.rs) with commands: show-system, show-body, show-station, list-bodies, list-stations, add-body, add-station, stats, populate. Reads from server/data/systems.db. Wrapper at tooling/atlas, skill at .claude/skills/atlas/SKILL.md. Scope note: atlas will grow to cover the full geographic hierarchy (planetary surfaces, settlements, districts) as the cascade progresses. Also: removed stale star_systems table from settledreach.db (belongs in systems.db only) and ran initial populate pass (329 bodies + 301 horizon stations across 301 systems). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
25 lines
616 B
Bash
Executable File
25 lines
616 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# Atlas CLI wrapper — celestial bodies and stations in systems.db.
|
|
#
|
|
# Usage:
|
|
# tooling/atlas stats
|
|
# tooling/atlas show-system "GJ 15A"
|
|
# tooling/atlas list-bodies --system "GJ 15A"
|
|
# tooling/atlas populate --dry-run
|
|
#
|
|
# Builds on first run if binary doesn't exist.
|
|
|
|
set -euo pipefail
|
|
|
|
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
ROOT_DIR="$(cd "$SCRIPT_DIR/.." && pwd)"
|
|
BIN="$ROOT_DIR/server/target/debug/atlas"
|
|
|
|
# Build if needed
|
|
if [ ! -f "$BIN" ]; then
|
|
echo "Building atlas..." >&2
|
|
(cd "$ROOT_DIR/server" && cargo build --bin atlas 2>&1 | tail -3) >&2
|
|
fi
|
|
|
|
exec "$BIN" "$@"
|