Files
settled-reach/tooling/db/sqlite-query
T
jpmschweitzerandClaude Opus 4.6 48c8fb7dea fix(ui): PR #131 review round 2 — manifest cleanup, system index helper, stderr help
Addresses 6 mechanical issues from PR review:

- ImplantAppManifest: drop dead display_name and icon_path fields.
  default_key carries a TODO noting its future migration to a keybinds
  manifest (input concern in app manifest is a layering violation,
  tracked explicitly).
- default_mode wire format is now a String ("fullscreen" / "insert") for
  mod-author discovery. ImplantRegistry parses via _MODE_MAP, caches the
  resolved int in _resolved_modes, and exposes get_resolved_mode(app_path).
  main.gd reads the resolved int directly instead of re-parsing.
- Extract client/ui/implant/widgets/system_index.gd (class_name SystemIndex,
  static get_sorted_systems). Removes duplicated star_map_data.json loader +
  sort lambda from atlas_app and economics overview_screen.
- ImplantApp.on_insert_deactivated() default auto-closes only when the app
  is active in INSERT mode. FULLSCREEN apps no longer spuriously close on
  insert state changes.
- tooling/db/sqlite-query and sqlite-exec: --help output goes to stderr
  (exit 0). Keeps stdout reserved for JSON payloads so JSON-parsing
  callers can't get silently corrupted.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-19 14:21:03 +02:00

16 lines
678 B
Bash
Executable File

#!/usr/bin/env bash
# Run a SELECT query on the ticketing database. Whitelistable command.
# Usage: sqlite-query "SELECT * FROM tickets WHERE status='in_progress'"
if [ "$1" = "--help" ] || [ "$1" = "-h" ]; then
echo "Usage: sqlite-query <SQL>" >&2
echo "" >&2
echo "Run a SELECT query on the ticketing database." >&2
echo "Output is JSON: {\"ok\": true, \"count\": N, \"rows\": [...]}" >&2
echo "" >&2
echo "Examples:" >&2
echo " sqlite-query \"SELECT id, title, status FROM tickets WHERE sprint_id=36\"" >&2
echo " sqlite-query \"SELECT * FROM tickets WHERE assigned_to='stig'\"" >&2
exit 0
fi
exec python3 "$(dirname "$0")/sqlite_connector.py" query "$@"