chore(config): remove $REPO_ROOT env var, use relative paths

Claude Code's CWD is always the worktree root, so all script
invocations work with plain relative paths (db/connectors/ticket,
db/connectors/qdrant-search, etc.). The REPO_ROOT environment
variable and its settings.local.json definitions are no longer needed.

Updated: CLAUDE.md, all skill files, qatux agent file.
The settings.local.json env sections were also removed across all
9 worktrees (non-git files, edited directly).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-02-12 16:54:12 +01:00
co-authored by Claude Opus 4.6
parent c21671d44c
commit 0784d484c4
8 changed files with 76 additions and 87 deletions
+16 -20
View File
@@ -22,7 +22,6 @@ docs/
sprints/ # Sprint briefings per team (server.md, client.md, copy.md, joint.md, etc.)
workshops/ # Workshop briefs and outputs (per-workshop subdirectories)
db/
commonwealth.db # SQLite ticketing database
schema.sql # Database schema
connectors/ # Connector scripts for SQLite and Qdrant
config.json # Endpoint configuration
@@ -51,39 +50,36 @@ See [docs/DEVOPS.md](docs/DEVOPS.md) for build, test, lint, and CI procedures. A
## Agent Instructions
### Path resolution
### Database
This project uses **git worktrees** — each team branch is a separate directory.
The `$REPO_ROOT` environment variable is pre-set per worktree via
`.claude/settings.local.json`. Use it as a prefix for all path-sensitive
commands (especially Bash calls to scripts and CLIs).
The ticketing database (`settledreach.db`) lives in the **parent directory** shared across all worktrees — it is not tracked in git. A backup is committed to `docs/backups/settledreach.db.backup` via main only.
### Before starting work
1. Read your sprint briefing at `$REPO_ROOT/docs/sprints/sprint-N/{team}.md` for current tasks
2. Use `"$REPO_ROOT/db/connectors/ticket" show <id>` for full ticket details
3. Read the relevant `$REPO_ROOT/decisions/*.md` domain file(s) referenced in the briefing
4. Background context: `$REPO_ROOT/docs/briefings/{your-name}.md`, `$REPO_ROOT/docs/discussions/`
1. Read your sprint briefing at `docs/sprints/sprint-N/{team}.md` for current tasks
2. Use `db/connectors/ticket show <id>` for full ticket details
3. Read the relevant `decisions/*.md` domain file(s) referenced in the briefing
4. Background context: `docs/briefings/{your-name}.md`, `docs/discussions/`
### Ticket and database access
**Prefer the ticket CLI over raw SQL.** The CLI handles column names, joins, and output formatting correctly:
```bash
"$REPO_ROOT/db/connectors/ticket" list --sprint 2 --team server
"$REPO_ROOT/db/connectors/ticket" show 78
"$REPO_ROOT/db/connectors/ticket" sprint --active
db/connectors/ticket list --sprint 2 --team server
db/connectors/ticket show 78
db/connectors/ticket sprint --active
```
Only fall back to raw SQL for queries the CLI doesn't support. **Never use the `sqlite3` CLI** — it crashes in Claude Code due to a known std::bad_alloc bug. Use the wrapper scripts instead:
```bash
"$REPO_ROOT/db/connectors/sqlite-query" "SELECT * FROM tickets WHERE status='in_progress'"
"$REPO_ROOT/db/connectors/sqlite-exec" "UPDATE tickets SET status='done' WHERE id=1"
db/connectors/sqlite-query "SELECT * FROM tickets WHERE status='in_progress'"
db/connectors/sqlite-exec "UPDATE tickets SET status='done' WHERE id=1"
```
### Qdrant / document search
```bash
"$REPO_ROOT/db/connectors/qdrant-search" "asymmetric information design"
"$REPO_ROOT/db/connectors/qdrant-index" docs/briefings/tyre.md
"$REPO_ROOT/db/connectors/qdrant-health"
"$REPO_ROOT/db/connectors/qdrant-count"
db/connectors/qdrant-search "asymmetric information design"
db/connectors/qdrant-index docs/briefings/tyre.md
db/connectors/qdrant-health
db/connectors/qdrant-count
```
### Gitea access (tea CLI)
@@ -119,7 +115,7 @@ Key rules:
- Decision IDs: `D-NNN` (confirmed), `Q-NNN` (open questions), `R-NNN` (rejected)
- Discussion rounds: numbered sequentially, archived to `docs/discussions/` when complete
- Briefings: one per agent, updated after decision-producing rounds
- Tickets: managed via `"$REPO_ROOT/db/connectors/ticket"` CLI or `/ticket` skill
- Tickets: managed via `db/connectors/ticket` CLI or `/ticket` skill
### Commit conventions
Use conventional commits with project-specific scopes: