migrate mosaic home to xdg config path

This commit is contained in:
Jason Woltje
2026-02-17 14:12:02 -06:00
parent e16ff8af70
commit c7f363b2d2
60 changed files with 330 additions and 330 deletions

View File

@@ -4,7 +4,7 @@ Date: 2026-02-17
Scope: Scope:
- `~/src/mosaic-bootstrap` - `~/src/mosaic-bootstrap`
- `~/src/agent-skills` - `~/src/agent-skills`
- Installed runtime check: `~/.mosaic` - Installed runtime check: `~/.config/mosaic`
## Findings ## Findings
@@ -31,7 +31,7 @@ Updated:
- `rails/qa/qa-queue-monitor.sh` - `rails/qa/qa-queue-monitor.sh`
Change: Change:
- Standardized handler paths to `~/.mosaic/rails/qa/...`. - Standardized handler paths to `~/.config/mosaic/rails/qa/...`.
### MF-002 + MF-003 (conditional loading/context detection) ### MF-002 + MF-003 (conditional loading/context detection)
Updated: Updated:
@@ -42,7 +42,7 @@ Updated:
Change: Change:
- Detection now recognizes both legacy and Mosaic patterns: - Detection now recognizes both legacy and Mosaic patterns:
- `agent-guides` (legacy compatibility) - `agent-guides` (legacy compatibility)
- `~/.mosaic/guides` - `~/.config/mosaic/guides`
- `Conditional Loading` - `Conditional Loading`
- `Conditional Context` - `Conditional Context`
@@ -58,8 +58,8 @@ Updated:
- `skills/pr-reviewer/SKILL.md` - `skills/pr-reviewer/SKILL.md`
Change: Change:
- Replaced all `~/.claude/scripts/git/...` with `~/.mosaic/rails/git/...`. - Replaced all `~/.claude/scripts/git/...` with `~/.config/mosaic/rails/git/...`.
- Replaced `~/.claude/skills/...` with `~/.mosaic/skills/...`. - Replaced `~/.claude/skills/...` with `~/.config/mosaic/skills/...`.
### MF-006 (worktree skill docs hierarchy) ### MF-006 (worktree skill docs hierarchy)
Updated: Updated:
@@ -84,7 +84,7 @@ Updated:
- `skills/systematic-debugging/CREATION-LOG.md` - `skills/systematic-debugging/CREATION-LOG.md`
Change: Change:
- Standardized references to `~/.mosaic/skills`. - Standardized references to `~/.config/mosaic/skills`.
- Removed stale Claude-only wording. - Removed stale Claude-only wording.
## Residual Legacy References (Intentional) ## Residual Legacy References (Intentional)
@@ -109,7 +109,7 @@ These are required to support existing Claude runtime integration while keeping
Executed checks: Executed checks:
- `rg -n "~/.claude|\\.claude/|agent-guides" ~/src/agent-skills -S` - `rg -n "~/.claude|\\.claude/|agent-guides" ~/src/agent-skills -S`
- Result: no matches after remediation. - Result: no matches after remediation.
- `rg -n "~/.mosaic/rails/(qa-hook|remediation-hook|qa-queue-monitor)" ~/src/mosaic-bootstrap -S` - `rg -n "~/.config/mosaic/rails/(qa-hook|remediation-hook|qa-queue-monitor)" ~/src/mosaic-bootstrap -S`
- Result: no invalid old-style QA rail paths remain. - Result: no invalid old-style QA rail paths remain.
- Installed runtime validation: - Installed runtime validation:
- `~/.mosaic` contains `rails/git`, `rails/portainer`, `rails/cicd`, `skills`, and `bin` tooling. - `~/.config/mosaic` contains `rails/git`, `rails/portainer`, `rails/cicd`, `skills`, and `bin` tooling.

View File

@@ -1,6 +1,6 @@
# Mosaic Agent Framework # Mosaic Agent Framework
`~/.mosaic` is the universal userspace standards layer (master) for all agent runtimes. `~/.config/mosaic` is the universal userspace standards layer (master) for all agent runtimes.
## Install Master Layer ## Install Master Layer
@@ -13,15 +13,15 @@ bash ~/src/mosaic-bootstrap/install.sh
## What It Provides ## What It Provides
- Shared standards document: `~/.mosaic/STANDARDS.md` - Shared standards document: `~/.config/mosaic/STANDARDS.md`
- Shared operational guides: `~/.mosaic/guides/` - Shared operational guides: `~/.config/mosaic/guides/`
- Shared quality rails/scripts: `~/.mosaic/rails/` - Shared quality rails/scripts: `~/.config/mosaic/rails/`
- Shared runtime-neutral presets/profiles: `~/.mosaic/profiles/` - Shared runtime-neutral presets/profiles: `~/.config/mosaic/profiles/`
- Runtime adapter docs: `~/.mosaic/adapters/` - Runtime adapter docs: `~/.config/mosaic/adapters/`
- Runtime overlays: `~/.mosaic/runtime/` - Runtime overlays: `~/.config/mosaic/runtime/`
- Shared wrapper commands: `~/.mosaic/bin/` - Shared wrapper commands: `~/.config/mosaic/bin/`
- Canonical skills directory: `~/.mosaic/skills` - Canonical skills directory: `~/.config/mosaic/skills`
- Local cross-runtime skills: `~/.mosaic/skills-local` - Local cross-runtime skills: `~/.config/mosaic/skills-local`
## Universal Skills ## Universal Skills
@@ -31,7 +31,7 @@ The installer syncs skills from:
into: into:
- `~/.mosaic/skills` - `~/.config/mosaic/skills`
Then links each skill into runtime directories: Then links each skill into runtime directories:
@@ -39,51 +39,51 @@ Then links each skill into runtime directories:
- `~/.codex/skills` - `~/.codex/skills`
- `~/.config/opencode/skills` - `~/.config/opencode/skills`
Local skills under `~/.mosaic/skills-local` are also linked into runtimes. Local skills under `~/.config/mosaic/skills-local` are also linked into runtimes.
Manual commands: Manual commands:
```bash ```bash
~/.mosaic/bin/mosaic-sync-skills ~/.config/mosaic/bin/mosaic-sync-skills
~/.mosaic/bin/mosaic-sync-skills --link-only ~/.config/mosaic/bin/mosaic-sync-skills --link-only
``` ```
## Runtime Compatibility Sync ## Runtime Compatibility Sync
Installer syncs runtime overlays as regular files (not symlinks): Installer syncs runtime overlays as regular files (not symlinks):
- `~/.claude/{CLAUDE.md,settings.json,hooks-config.json,context7-integration.md}` <- `~/.mosaic/runtime/claude/...` - `~/.claude/{CLAUDE.md,settings.json,hooks-config.json,context7-integration.md}` <- `~/.config/mosaic/runtime/claude/...`
- `~/.config/opencode/AGENTS.md` <- `~/.mosaic/runtime/opencode/AGENTS.md` - `~/.config/opencode/AGENTS.md` <- `~/.config/mosaic/runtime/opencode/AGENTS.md`
Legacy symlink trees under `~/.claude` for migrated guides/scripts/templates/presets are pruned during sync. Legacy symlink trees under `~/.claude` for migrated guides/scripts/templates/presets are pruned during sync.
Run manually: Run manually:
```bash ```bash
~/.mosaic/bin/mosaic-link-runtime-assets ~/.config/mosaic/bin/mosaic-link-runtime-assets
~/.mosaic/bin/mosaic-migrate-local-skills --apply ~/.config/mosaic/bin/mosaic-migrate-local-skills --apply
``` ```
Prune migrated legacy backups from runtime folders (dry-run by default): Prune migrated legacy backups from runtime folders (dry-run by default):
```bash ```bash
~/.mosaic/bin/mosaic-prune-legacy-runtime --runtime claude ~/.config/mosaic/bin/mosaic-prune-legacy-runtime --runtime claude
~/.mosaic/bin/mosaic-prune-legacy-runtime --runtime claude --apply ~/.config/mosaic/bin/mosaic-prune-legacy-runtime --runtime claude --apply
``` ```
Clean empty legacy runtime directories: Clean empty legacy runtime directories:
```bash ```bash
~/.mosaic/bin/mosaic-clean-runtime --runtime claude ~/.config/mosaic/bin/mosaic-clean-runtime --runtime claude
~/.mosaic/bin/mosaic-clean-runtime --runtime claude --apply ~/.config/mosaic/bin/mosaic-clean-runtime --runtime claude --apply
~/.mosaic/bin/mosaic-clean-runtime --runtime claude --all-empty --apply ~/.config/mosaic/bin/mosaic-clean-runtime --runtime claude --all-empty --apply
``` ```
Audit runtime drift: Audit runtime drift:
```bash ```bash
~/.mosaic/bin/mosaic-doctor ~/.config/mosaic/bin/mosaic-doctor
~/.mosaic/bin/mosaic-doctor --fail-on-warn ~/.config/mosaic/bin/mosaic-doctor --fail-on-warn
``` ```
Opt-out during install: Opt-out during install:
@@ -97,9 +97,9 @@ MOSAIC_SKIP_SKILLS_SYNC=1 bash ~/src/mosaic-bootstrap/install.sh
Inside any compatible repository: Inside any compatible repository:
```bash ```bash
~/.mosaic/bin/mosaic-session-start ~/.config/mosaic/bin/mosaic-session-start
~/.mosaic/bin/mosaic-critical ~/.config/mosaic/bin/mosaic-critical
~/.mosaic/bin/mosaic-session-end ~/.config/mosaic/bin/mosaic-session-end
``` ```
Wrapper commands call local repo scripts under `scripts/agent/`. Wrapper commands call local repo scripts under `scripts/agent/`.
@@ -108,18 +108,18 @@ Wrapper commands call local repo scripts under `scripts/agent/`.
Mosaic includes vendored quality-rails templates and scripts at: Mosaic includes vendored quality-rails templates and scripts at:
- `~/.mosaic/rails/quality/` - `~/.config/mosaic/rails/quality/`
Apply to a repo: Apply to a repo:
```bash ```bash
~/.mosaic/bin/mosaic-quality-apply --template typescript-node --target /path/to/repo ~/.config/mosaic/bin/mosaic-quality-apply --template typescript-node --target /path/to/repo
``` ```
Verify enforcement: Verify enforcement:
```bash ```bash
~/.mosaic/bin/mosaic-quality-verify --target /path/to/repo ~/.config/mosaic/bin/mosaic-quality-verify --target /path/to/repo
``` ```
Templates currently supported: Templates currently supported:
@@ -132,16 +132,16 @@ Templates currently supported:
Mosaic includes a runtime-agnostic orchestrator rail at: Mosaic includes a runtime-agnostic orchestrator rail at:
- `~/.mosaic/rails/orchestrator-matrix/` - `~/.config/mosaic/rails/orchestrator-matrix/`
Run from a bootstrapped repo: Run from a bootstrapped repo:
```bash ```bash
~/.mosaic/bin/mosaic-orchestrator-matrix-cycle ~/.config/mosaic/bin/mosaic-orchestrator-matrix-cycle
~/.mosaic/bin/mosaic-orchestrator-run --once ~/.config/mosaic/bin/mosaic-orchestrator-run --once
~/.mosaic/bin/mosaic-orchestrator-run --poll-sec 10 ~/.config/mosaic/bin/mosaic-orchestrator-run --poll-sec 10
~/.mosaic/bin/mosaic-orchestrator-matrix-publish ~/.config/mosaic/bin/mosaic-orchestrator-matrix-publish
~/.mosaic/bin/mosaic-orchestrator-matrix-consume ~/.config/mosaic/bin/mosaic-orchestrator-matrix-consume
``` ```
The controller reads/writes repo-local state in `.mosaic/orchestrator/` and emits The controller reads/writes repo-local state in `.mosaic/orchestrator/` and emits
@@ -152,13 +152,13 @@ structured events to `.mosaic/orchestrator/events.ndjson` for Matrix bridge cons
Attach any repository/workspace to the master layer: Attach any repository/workspace to the master layer:
```bash ```bash
~/.mosaic/bin/mosaic-bootstrap-repo /path/to/repo ~/.config/mosaic/bin/mosaic-bootstrap-repo /path/to/repo
``` ```
Attach and apply quality rails in one step: Attach and apply quality rails in one step:
```bash ```bash
~/.mosaic/bin/mosaic-bootstrap-repo --quality-template typescript-node /path/to/repo ~/.config/mosaic/bin/mosaic-bootstrap-repo --quality-template typescript-node /path/to/repo
``` ```
This creates/updates: This creates/updates:
@@ -172,11 +172,11 @@ This creates/updates:
Preview upgrades (dry-run): Preview upgrades (dry-run):
```bash ```bash
~/.mosaic/bin/mosaic-upgrade-slaves ~/.config/mosaic/bin/mosaic-upgrade-slaves
``` ```
Apply upgrades: Apply upgrades:
```bash ```bash
~/.mosaic/bin/mosaic-upgrade-slaves --apply ~/.config/mosaic/bin/mosaic-upgrade-slaves --apply
``` ```

View File

@@ -3,7 +3,7 @@
This file is the canonical standards contract for agent sessions on this machine. This file is the canonical standards contract for agent sessions on this machine.
Master/slave model: Master/slave model:
- Master: `~/.mosaic` (this framework) - Master: `~/.config/mosaic` (this framework)
- Slave: each repo bootstrapped via `mosaic-bootstrap-repo` - Slave: each repo bootstrapped via `mosaic-bootstrap-repo`
## Execution Model ## Execution Model
@@ -12,16 +12,16 @@ Master/slave model:
2. Load project-local `AGENTS.md` next. 2. Load project-local `AGENTS.md` next.
3. Respect repository-specific tooling and workflows. 3. Respect repository-specific tooling and workflows.
4. Use lifecycle scripts when available (`scripts/agent/*.sh`). 4. Use lifecycle scripts when available (`scripts/agent/*.sh`).
5. Use shared rails/guides from `~/.mosaic` as canonical references. 5. Use shared rails/guides from `~/.config/mosaic` as canonical references.
## Non-Negotiables ## Non-Negotiables
- Data files are authoritative; generated views are derived artifacts. - Data files are authoritative; generated views are derived artifacts.
- Pull before edits when collaborating in shared repos. - Pull before edits when collaborating in shared repos.
- Run validation checks before claiming completion. - Run validation checks before claiming completion.
- Apply quality rails from `~/.mosaic/rails/` when relevant (review, QA, git workflow). - Apply quality rails from `~/.config/mosaic/rails/` when relevant (review, QA, git workflow).
- For project-level mechanical enforcement templates, use `~/.mosaic/rails/quality/` via `~/.mosaic/bin/mosaic-quality-apply`. - For project-level mechanical enforcement templates, use `~/.config/mosaic/rails/quality/` via `~/.config/mosaic/bin/mosaic-quality-apply`.
- For runtime-agnostic delegation/orchestration, use `~/.mosaic/rails/orchestrator-matrix/` with repo-local `.mosaic/orchestrator/` state. - For runtime-agnostic delegation/orchestration, use `~/.config/mosaic/rails/orchestrator-matrix/` with repo-local `.mosaic/orchestrator/` state.
- Avoid hardcoded secrets and token leakage in remotes/commits. - Avoid hardcoded secrets and token leakage in remotes/commits.
- Do not perform destructive git/file actions without explicit instruction. - Do not perform destructive git/file actions without explicit instruction.
@@ -44,15 +44,15 @@ If a repo does not expose these scripts, run equivalent local workflow commands
All runtime adapters should inject: All runtime adapters should inject:
- `~/.mosaic/STANDARDS.md` - `~/.config/mosaic/STANDARDS.md`
- project `AGENTS.md` - project `AGENTS.md`
before task execution. before task execution.
Runtime-compatible guides and rails are hosted at: Runtime-compatible guides and rails are hosted at:
- `~/.mosaic/guides/` - `~/.config/mosaic/guides/`
- `~/.mosaic/rails/` - `~/.config/mosaic/rails/`
- `~/.mosaic/profiles/` (runtime-neutral domain/workflow/stack presets) - `~/.config/mosaic/profiles/` (runtime-neutral domain/workflow/stack presets)
- `~/.mosaic/runtime/` (runtime-specific overlays) - `~/.config/mosaic/runtime/` (runtime-specific overlays)
- `~/.mosaic/skills-local/` (local private skills shared across runtimes) - `~/.config/mosaic/skills-local/` (local private skills shared across runtimes)

View File

@@ -4,14 +4,14 @@ Use this adapter when running Claude CLI sessions.
## Required Context ## Required Context
1. `~/.mosaic/STANDARDS.md` 1. `~/.config/mosaic/STANDARDS.md`
2. `<repo>/AGENTS.md` 2. `<repo>/AGENTS.md`
## Command Wrapper ## Command Wrapper
Use wrapper commands from `~/.mosaic/bin/` for lifecycle rituals. Use wrapper commands from `~/.config/mosaic/bin/` for lifecycle rituals.
## Migration Note ## Migration Note
Project-local `.claude/commands/*.md` should call `scripts/agent/*.sh` so behavior stays runtime-neutral. Project-local `.claude/commands/*.md` should call `scripts/agent/*.sh` so behavior stays runtime-neutral.
Guides and rails should resolve to `~/.mosaic/guides` and `~/.mosaic/rails` (linked into `~/.claude` for compatibility). Guides and rails should resolve to `~/.config/mosaic/guides` and `~/.config/mosaic/rails` (linked into `~/.claude` for compatibility).

View File

@@ -4,7 +4,7 @@ Use this adapter when running Codex CLI sessions.
## Required Context ## Required Context
1. `~/.mosaic/STANDARDS.md` 1. `~/.config/mosaic/STANDARDS.md`
2. `<repo>/AGENTS.md` 2. `<repo>/AGENTS.md`
## Runtime Behavior ## Runtime Behavior

View File

@@ -4,7 +4,7 @@ For runtimes without a first-class adapter yet.
## Required Context ## Required Context
1. Load `~/.mosaic/STANDARDS.md` 1. Load `~/.config/mosaic/STANDARDS.md`
2. Load project `AGENTS.md` 2. Load project `AGENTS.md`
## Minimal Contract ## Minimal Contract

View File

@@ -27,12 +27,12 @@ if [[ ! -d "$TARGET_DIR" ]]; then
exit 1 exit 1
fi fi
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
TEMPLATE_ROOT="$MOSAIC_HOME/templates/repo" TEMPLATE_ROOT="$MOSAIC_HOME/templates/repo"
if [[ ! -d "$TEMPLATE_ROOT" ]]; then if [[ ! -d "$TEMPLATE_ROOT" ]]; then
echo "[mosaic] Missing templates at $TEMPLATE_ROOT" >&2 echo "[mosaic] Missing templates at $TEMPLATE_ROOT" >&2
echo "[mosaic] Install or refresh framework: ~/.mosaic/install.sh" >&2 echo "[mosaic] Install or refresh framework: ~/.config/mosaic/install.sh" >&2
exit 1 exit 1
fi fi
@@ -74,7 +74,7 @@ if [[ ! -f "$TARGET_DIR/AGENTS.md" ]]; then
## Standards Load Order ## Standards Load Order
1. `~/.mosaic/STANDARDS.md` 1. `~/.config/mosaic/STANDARDS.md`
2. `AGENTS.md` (this file) 2. `AGENTS.md` (this file)
3. `.mosaic/repo-hooks.sh` 3. `.mosaic/repo-hooks.sh`
@@ -88,8 +88,8 @@ bash scripts/agent/session-end.sh
## Shared Rails ## Shared Rails
- Quality and orchestration guides: `~/.mosaic/guides/` - Quality and orchestration guides: `~/.config/mosaic/guides/`
- Shared automation rails: `~/.mosaic/rails/` - Shared automation rails: `~/.config/mosaic/rails/`
## Repo-Specific Notes ## Repo-Specific Notes
@@ -103,8 +103,8 @@ fi
echo "[mosaic] Repo bootstrap complete: $TARGET_DIR" echo "[mosaic] Repo bootstrap complete: $TARGET_DIR"
echo "[mosaic] Next: edit $TARGET_DIR/.mosaic/repo-hooks.sh with project workflows" echo "[mosaic] Next: edit $TARGET_DIR/.mosaic/repo-hooks.sh with project workflows"
echo "[mosaic] Optional: apply quality rails via ~/.mosaic/bin/mosaic-quality-apply --template <template> --target $TARGET_DIR" echo "[mosaic] Optional: apply quality rails via ~/.config/mosaic/bin/mosaic-quality-apply --template <template> --target $TARGET_DIR"
echo "[mosaic] Optional: run orchestrator rail via ~/.mosaic/bin/mosaic-orchestrator-matrix-cycle" echo "[mosaic] Optional: run orchestrator rail via ~/.config/mosaic/bin/mosaic-orchestrator-matrix-cycle"
if [[ -n "$QUALITY_TEMPLATE" ]]; then if [[ -n "$QUALITY_TEMPLATE" ]]; then
if [[ -x "$MOSAIC_HOME/bin/mosaic-quality-apply" ]]; then if [[ -x "$MOSAIC_HOME/bin/mosaic-quality-apply" ]]; then

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
FAIL_ON_WARN=0 FAIL_ON_WARN=0
VERBOSE=0 VERBOSE=0

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
backup_stamp="$(date +%Y%m%d%H%M%S)" backup_stamp="$(date +%Y%m%d%H%M%S)"
copy_file_managed() { copy_file_managed() {

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
APPLY=0 APPLY=0
usage() { usage() {
@@ -9,7 +9,7 @@ usage() {
Usage: $(basename "$0") [--apply] Usage: $(basename "$0") [--apply]
Migrate runtime-local skill directories (e.g. ~/.claude/skills/jarvis) to Mosaic-managed Migrate runtime-local skill directories (e.g. ~/.claude/skills/jarvis) to Mosaic-managed
skills by replacing local directories with symlinks to ~/.mosaic/skills-local. skills by replacing local directories with symlinks to ~/.config/mosaic/skills-local.
Default mode is dry-run. Default mode is dry-run.
USAGE USAGE

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
BRIDGE="$MOSAIC_HOME/rails/orchestrator-matrix/transport/matrix_transport.py" BRIDGE="$MOSAIC_HOME/rails/orchestrator-matrix/transport/matrix_transport.py"
if [[ ! -f "$BRIDGE" ]]; then if [[ ! -f "$BRIDGE" ]]; then

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
consume="$MOSAIC_HOME/bin/mosaic-orchestrator-matrix-consume" consume="$MOSAIC_HOME/bin/mosaic-orchestrator-matrix-consume"
run="$MOSAIC_HOME/bin/mosaic-orchestrator-run" run="$MOSAIC_HOME/bin/mosaic-orchestrator-run"

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
BRIDGE="$MOSAIC_HOME/rails/orchestrator-matrix/transport/matrix_transport.py" BRIDGE="$MOSAIC_HOME/rails/orchestrator-matrix/transport/matrix_transport.py"
if [[ ! -f "$BRIDGE" ]]; then if [[ ! -f "$BRIDGE" ]]; then

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
CTRL="$MOSAIC_HOME/rails/orchestrator-matrix/controller/mosaic_orchestrator.py" CTRL="$MOSAIC_HOME/rails/orchestrator-matrix/controller/mosaic_orchestrator.py"
if [[ ! -f "$CTRL" ]]; then if [[ ! -f "$CTRL" ]]; then

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
RUNTIME="claude" RUNTIME="claude"
APPLY=0 APPLY=0
@@ -10,7 +10,7 @@ usage() {
Usage: $(basename "$0") [options] Usage: $(basename "$0") [options]
Remove legacy runtime files that were preserved as *.mosaic-bak-* after Mosaic linking. Remove legacy runtime files that were preserved as *.mosaic-bak-* after Mosaic linking.
Only removes backups when the active file is a symlink to ~/.mosaic. Only removes backups when the active file is a symlink to ~/.config/mosaic.
Options: Options:
--runtime <name> Runtime to prune (default: claude) --runtime <name> Runtime to prune (default: claude)

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
TARGET_DIR="$(pwd)" TARGET_DIR="$(pwd)"
TEMPLATE="" TEMPLATE=""

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
TARGET_DIR="$(pwd)" TARGET_DIR="$(pwd)"
usage() { usage() {

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
SKILLS_REPO_URL="${MOSAIC_SKILLS_REPO_URL:-https://git.mosaicstack.dev/mosaic/agent-skills.git}" SKILLS_REPO_URL="${MOSAIC_SKILLS_REPO_URL:-https://git.mosaicstack.dev/mosaic/agent-skills.git}"
SKILLS_REPO_DIR="${MOSAIC_SKILLS_REPO_DIR:-$MOSAIC_HOME/sources/agent-skills}" SKILLS_REPO_DIR="${MOSAIC_SKILLS_REPO_DIR:-$MOSAIC_HOME/sources/agent-skills}"
MOSAIC_SKILLS_DIR="$MOSAIC_HOME/skills" MOSAIC_SKILLS_DIR="$MOSAIC_HOME/skills"
@@ -14,17 +14,17 @@ usage() {
cat <<USAGE cat <<USAGE
Usage: $(basename "$0") [options] Usage: $(basename "$0") [options]
Sync canonical skills into ~/.mosaic/skills and link all Mosaic skills into runtime skill directories. Sync canonical skills into ~/.config/mosaic/skills and link all Mosaic skills into runtime skill directories.
Options: Options:
--link-only Skip git clone/pull and only relink from ~/.mosaic/{skills,skills-local} --link-only Skip git clone/pull and only relink from ~/.config/mosaic/{skills,skills-local}
--no-link Sync canonical skills but do not update runtime links --no-link Sync canonical skills but do not update runtime links
-h, --help Show help -h, --help Show help
Env: Env:
MOSAIC_HOME Default: ~/.mosaic MOSAIC_HOME Default: ~/.config/mosaic
MOSAIC_SKILLS_REPO_URL Default: https://git.mosaicstack.dev/mosaic/agent-skills.git MOSAIC_SKILLS_REPO_URL Default: https://git.mosaicstack.dev/mosaic/agent-skills.git
MOSAIC_SKILLS_REPO_DIR Default: ~/.mosaic/sources/agent-skills MOSAIC_SKILLS_REPO_DIR Default: ~/.config/mosaic/sources/agent-skills
USAGE USAGE
} }

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -euo pipefail set -euo pipefail
MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.mosaic}" MOSAIC_HOME="${MOSAIC_HOME:-$HOME/.config/mosaic}"
BOOTSTRAP_CMD="$MOSAIC_HOME/bin/mosaic-bootstrap-repo" BOOTSTRAP_CMD="$MOSAIC_HOME/bin/mosaic-bootstrap-repo"
roots=("$HOME/src") roots=("$HOME/src")
@@ -45,7 +45,7 @@ done
if [[ ! -x "$BOOTSTRAP_CMD" ]]; then if [[ ! -x "$BOOTSTRAP_CMD" ]]; then
echo "[mosaic-upgrade] Missing bootstrap command: $BOOTSTRAP_CMD" >&2 echo "[mosaic-upgrade] Missing bootstrap command: $BOOTSTRAP_CMD" >&2
echo "[mosaic-upgrade] Install/refresh framework first: ~/.mosaic/install.sh" >&2 echo "[mosaic-upgrade] Install/refresh framework first: ~/.config/mosaic/install.sh" >&2
exit 1 exit 1
fi fi

View File

@@ -1,7 +1,7 @@
# Authentication & Authorization Guide # Authentication & Authorization Guide
## Before Starting ## Before Starting
1. Check assigned issue: `~/.mosaic/rails/git/issue-list.sh -a @me` 1. Check assigned issue: `~/.config/mosaic/rails/git/issue-list.sh -a @me`
2. Review existing auth implementation in codebase 2. Review existing auth implementation in codebase
3. Review Vault secrets structure: `docs/vault-secrets-structure.md` 3. Review Vault secrets structure: `docs/vault-secrets-structure.md`

View File

@@ -1,7 +1,7 @@
# Backend Development Guide # Backend Development Guide
## Before Starting ## Before Starting
1. Check assigned issue: `~/.mosaic/rails/git/issue-list.sh -a @me` 1. Check assigned issue: `~/.config/mosaic/rails/git/issue-list.sh -a @me`
2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md` 2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md`
3. Review API contracts and database schema 3. Review API contracts and database schema
@@ -47,7 +47,7 @@
- Use project's established auth pattern - Use project's established auth pattern
- Validate tokens on every request - Validate tokens on every request
- Check permissions before operations - Check permissions before operations
- See `~/.mosaic/guides/authentication.md` for details - See `~/.config/mosaic/guides/authentication.md` for details
## Testing Requirements (TDD) ## Testing Requirements (TDD)
1. Write tests BEFORE implementation 1. Write tests BEFORE implementation
@@ -73,7 +73,7 @@ class TestResourceEndpoint:
## Code Style ## Code Style
- Follow Google Style Guide for your language - Follow Google Style Guide for your language
- **TypeScript: Follow `~/.mosaic/guides/typescript.md` — MANDATORY** - **TypeScript: Follow `~/.config/mosaic/guides/typescript.md` — MANDATORY**
- Use linter/formatter from project configuration - Use linter/formatter from project configuration
- Keep functions focused and small - Keep functions focused and small
- Document complex business logic - Document complex business logic

View File

@@ -15,7 +15,7 @@ This guide covers how to bootstrap a project so AI agents (Claude, Codex, etc.)
```bash ```bash
# Automated bootstrap (recommended) # Automated bootstrap (recommended)
~/.mosaic/rails/bootstrap/init-project.sh \ ~/.config/mosaic/rails/bootstrap/init-project.sh \
--name "my-project" \ --name "my-project" \
--type "nestjs-nextjs" \ --type "nestjs-nextjs" \
--repo "https://git.mosaicstack.dev/owner/repo" --repo "https://git.mosaicstack.dev/owner/repo"
@@ -24,8 +24,8 @@ This guide covers how to bootstrap a project so AI agents (Claude, Codex, etc.)
export PROJECT_NAME="My Project" export PROJECT_NAME="My Project"
export PROJECT_DESCRIPTION="What this project does" export PROJECT_DESCRIPTION="What this project does"
export TASK_PREFIX="MP" export TASK_PREFIX="MP"
envsubst < ~/.mosaic/templates/agent/CLAUDE.md.template > CLAUDE.md envsubst < ~/.config/mosaic/templates/agent/CLAUDE.md.template > CLAUDE.md
envsubst < ~/.mosaic/templates/agent/AGENTS.md.template > AGENTS.md envsubst < ~/.config/mosaic/templates/agent/AGENTS.md.template > AGENTS.md
``` ```
--- ---
@@ -86,12 +86,12 @@ export TASK_PREFIX="MP"
# Use tech-stack-specific template if available # Use tech-stack-specific template if available
TYPE=$(detect_project_type) TYPE=$(detect_project_type)
TEMPLATE_DIR="$HOME/.mosaic/templates/agent/projects/$TYPE" TEMPLATE_DIR="$HOME/.config/mosaic/templates/agent/projects/$TYPE"
if [[ -d "$TEMPLATE_DIR" ]]; then if [[ -d "$TEMPLATE_DIR" ]]; then
envsubst < "$TEMPLATE_DIR/CLAUDE.md.template" > CLAUDE.md envsubst < "$TEMPLATE_DIR/CLAUDE.md.template" > CLAUDE.md
else else
envsubst < "$HOME/.mosaic/templates/agent/CLAUDE.md.template" > CLAUDE.md envsubst < "$HOME/.config/mosaic/templates/agent/CLAUDE.md.template" > CLAUDE.md
fi fi
``` ```
@@ -116,7 +116,7 @@ export LINT_COMMAND="ruff check ."
export TYPECHECK_COMMAND="mypy ." export TYPECHECK_COMMAND="mypy ."
export QUALITY_GATES="ruff check . && mypy . && pytest tests/" export QUALITY_GATES="ruff check . && mypy . && pytest tests/"
envsubst < ~/.mosaic/templates/agent/CLAUDE.md.template > CLAUDE.md envsubst < ~/.config/mosaic/templates/agent/CLAUDE.md.template > CLAUDE.md
``` ```
### Required Sections ### Required Sections
@@ -141,12 +141,12 @@ The `AGENTS.md` file contains agent-specific patterns, gotchas, and orchestrator
```bash ```bash
TYPE=$(detect_project_type) TYPE=$(detect_project_type)
TEMPLATE_DIR="$HOME/.mosaic/templates/agent/projects/$TYPE" TEMPLATE_DIR="$HOME/.config/mosaic/templates/agent/projects/$TYPE"
if [[ -d "$TEMPLATE_DIR" ]]; then if [[ -d "$TEMPLATE_DIR" ]]; then
envsubst < "$TEMPLATE_DIR/AGENTS.md.template" > AGENTS.md envsubst < "$TEMPLATE_DIR/AGENTS.md.template" > AGENTS.md
else else
envsubst < "$HOME/.mosaic/templates/agent/AGENTS.md.template" > AGENTS.md envsubst < "$HOME/.config/mosaic/templates/agent/AGENTS.md.template" > AGENTS.md
fi fi
``` ```
@@ -175,10 +175,10 @@ mkdir -p docs/reports
```bash ```bash
# Use the init script # Use the init script
~/.mosaic/rails/bootstrap/init-repo-labels.sh ~/.config/mosaic/rails/bootstrap/init-repo-labels.sh
# Or manually create standard labels # Or manually create standard labels
~/.mosaic/rails/git/issue-create.sh # (labels are created on first use) ~/.config/mosaic/rails/git/issue-create.sh # (labels are created on first use)
``` ```
### Standard Labels ### Standard Labels
@@ -198,7 +198,7 @@ mkdir -p docs/reports
Create the first milestone for MVP: Create the first milestone for MVP:
```bash ```bash
~/.mosaic/rails/git/milestone-create.sh -t "0.1.0" -d "MVP - Minimum Viable Product" ~/.config/mosaic/rails/git/milestone-create.sh -t "0.1.0" -d "MVP - Minimum Viable Product"
``` ```
--- ---
@@ -210,8 +210,8 @@ Create the first milestone for MVP:
```bash ```bash
# Copy Codex review pipeline # Copy Codex review pipeline
mkdir -p .woodpecker/schemas mkdir -p .woodpecker/schemas
cp ~/.mosaic/rails/codex/woodpecker/codex-review.yml .woodpecker/ cp ~/.config/mosaic/rails/codex/woodpecker/codex-review.yml .woodpecker/
cp ~/.mosaic/rails/codex/schemas/*.json .woodpecker/schemas/ cp ~/.config/mosaic/rails/codex/schemas/*.json .woodpecker/schemas/
# Add codex_api_key secret to Woodpecker CI dashboard # Add codex_api_key secret to Woodpecker CI dashboard
``` ```
@@ -243,7 +243,7 @@ grep -c "Code Review" CLAUDE.md
eval "$(grep -A1 'Quality Gates' CLAUDE.md | tail -1)" eval "$(grep -A1 'Quality Gates' CLAUDE.md | tail -1)"
# Test Codex review (if configured) # Test Codex review (if configured)
~/.mosaic/rails/codex/codex-code-review.sh --help ~/.config/mosaic/rails/codex/codex-code-review.sh --help
``` ```
--- ---
@@ -254,15 +254,15 @@ eval "$(grep -A1 'Quality Gates' CLAUDE.md | tail -1)"
| Template | Path | Purpose | | Template | Path | Purpose |
|----------|------|---------| |----------|------|---------|
| `CLAUDE.md.template` | `~/.mosaic/templates/agent/` | Generic project CLAUDE.md | | `CLAUDE.md.template` | `~/.config/mosaic/templates/agent/` | Generic project CLAUDE.md |
| `AGENTS.md.template` | `~/.mosaic/templates/agent/` | Generic agent context | | `AGENTS.md.template` | `~/.config/mosaic/templates/agent/` | Generic agent context |
### Tech-Stack Templates ### Tech-Stack Templates
| Stack | Path | Includes | | Stack | Path | Includes |
|-------|------|----------| |-------|------|----------|
| NestJS + Next.js | `~/.mosaic/templates/agent/projects/nestjs-nextjs/` | CLAUDE.md, AGENTS.md | | NestJS + Next.js | `~/.config/mosaic/templates/agent/projects/nestjs-nextjs/` | CLAUDE.md, AGENTS.md |
| Django | `~/.mosaic/templates/agent/projects/django/` | CLAUDE.md, AGENTS.md | | Django | `~/.config/mosaic/templates/agent/projects/django/` | CLAUDE.md, AGENTS.md |
### Orchestrator Templates ### Orchestrator Templates
@@ -305,7 +305,7 @@ eval "$(grep -A1 'Quality Gates' CLAUDE.md | tail -1)"
Full project bootstrap with interactive and flag-based modes: Full project bootstrap with interactive and flag-based modes:
```bash ```bash
~/.mosaic/rails/bootstrap/init-project.sh \ ~/.config/mosaic/rails/bootstrap/init-project.sh \
--name "My Project" \ --name "My Project" \
--type "nestjs-nextjs" \ --type "nestjs-nextjs" \
--repo "https://git.mosaicstack.dev/owner/repo" \ --repo "https://git.mosaicstack.dev/owner/repo" \
@@ -318,7 +318,7 @@ Full project bootstrap with interactive and flag-based modes:
Initialize standard labels and MVP milestone: Initialize standard labels and MVP milestone:
```bash ```bash
~/.mosaic/rails/bootstrap/init-repo-labels.sh ~/.config/mosaic/rails/bootstrap/init-repo-labels.sh
``` ```
--- ---
@@ -335,4 +335,4 @@ After bootstrapping, verify:
- [ ] Quality gates run successfully - [ ] Quality gates run successfully
- [ ] `.env.example` exists (if project uses env vars) - [ ] `.env.example` exists (if project uses env vars)
- [ ] CI/CD pipeline configured (if using Woodpecker/GitHub Actions) - [ ] CI/CD pipeline configured (if using Woodpecker/GitHub Actions)
- [ ] Codex review scripts accessible (`~/.mosaic/rails/codex/`) - [ ] Codex review scripts accessible (`~/.config/mosaic/rails/codex/`)

View File

@@ -64,7 +64,7 @@
### Getting Context ### Getting Context
```bash ```bash
# List the issue being addressed # List the issue being addressed
~/.mosaic/rails/git/issue-list.sh -i {issue-number} ~/.config/mosaic/rails/git/issue-list.sh -i {issue-number}
# View the changes # View the changes
git diff main...HEAD git diff main...HEAD

View File

@@ -1,7 +1,7 @@
# Frontend Development Guide # Frontend Development Guide
## Before Starting ## Before Starting
1. Check assigned issue in git repo: `~/.mosaic/rails/git/issue-list.sh -a @me` 1. Check assigned issue in git repo: `~/.config/mosaic/rails/git/issue-list.sh -a @me`
2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md` 2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md`
3. Review existing components and patterns in the codebase 3. Review existing components and patterns in the codebase
@@ -49,7 +49,7 @@ describe('ComponentName', () => {
## Code Style ## Code Style
- Follow Google JavaScript/TypeScript Style Guide - Follow Google JavaScript/TypeScript Style Guide
- **TypeScript: Follow `~/.mosaic/guides/typescript.md` — MANDATORY** - **TypeScript: Follow `~/.config/mosaic/guides/typescript.md` — MANDATORY**
- Use ESLint/Prettier configuration from project - Use ESLint/Prettier configuration from project
- Prefer functional components over class components (React) - Prefer functional components over class components (React)
- TypeScript strict mode is REQUIRED, not optional - TypeScript strict mode is REQUIRED, not optional

View File

@@ -1,7 +1,7 @@
# Infrastructure & DevOps Guide # Infrastructure & DevOps Guide
## Before Starting ## Before Starting
1. Check assigned issue: `~/.mosaic/rails/git/issue-list.sh -a @me` 1. Check assigned issue: `~/.config/mosaic/rails/git/issue-list.sh -a @me`
2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md` 2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md`
3. Review existing infrastructure configuration 3. Review existing infrastructure configuration

View File

@@ -50,8 +50,8 @@ Choose one delegation mode at session start:
Matrix rail mode commands: Matrix rail mode commands:
```bash ```bash
~/.mosaic/bin/mosaic-orchestrator-matrix-cycle ~/.config/mosaic/bin/mosaic-orchestrator-matrix-cycle
~/.mosaic/bin/mosaic-orchestrator-run --poll-sec 10 ~/.config/mosaic/bin/mosaic-orchestrator-run --poll-sec 10
``` ```
In Matrix rail mode, keep `docs/tasks.md` as canonical project tracking and use In Matrix rail mode, keep `docs/tasks.md` as canonical project tracking and use
@@ -186,7 +186,7 @@ Use these heuristics based on task type:
Create ONE issue per phase using git scripts: Create ONE issue per phase using git scripts:
```bash ```bash
~/.mosaic/rails/git/issue-create.sh \ ~/.config/mosaic/rails/git/issue-create.sh \
-t "Phase 1: Critical Security Fixes" \ -t "Phase 1: Critical Security Fixes" \
-b "$(cat <<'EOF' -b "$(cat <<'EOF'
## Findings ## Findings
@@ -309,10 +309,10 @@ Run review when the worker's result includes code changes (commits). Skip for ta
cd {project_path} cd {project_path}
# Code quality review # Code quality review
~/.mosaic/rails/codex/codex-code-review.sh -b {base_branch} -o /tmp/review-{task_id}.json ~/.config/mosaic/rails/codex/codex-code-review.sh -b {base_branch} -o /tmp/review-{task_id}.json
# Security review # Security review
~/.mosaic/rails/codex/codex-security-review.sh -b {base_branch} -o /tmp/security-{task_id}.json ~/.config/mosaic/rails/codex/codex-security-review.sh -b {base_branch} -o /tmp/security-{task_id}.json
``` ```
### Step 2: Parse Review Results ### Step 2: Parse Review Results
@@ -373,7 +373,7 @@ Review the code changes on branch {branch} against {base_branch}.
- Security (OWASP Top 10, secrets, injection) - Security (OWASP Top 10, secrets, injection)
- Testing (coverage, quality) - Testing (coverage, quality)
- Code quality (complexity, duplication) - Code quality (complexity, duplication)
3. Reference: ~/.mosaic/guides/code-review.md 3. Reference: ~/.config/mosaic/guides/code-review.md
Report findings as JSON: Report findings as JSON:
```json ```json
@@ -448,8 +448,8 @@ Construct this from the task row and pass to worker via Task tool:
## Git Scripts ## Git Scripts
For issue/PR/milestone operations, use scripts (NOT raw tea/gh): For issue/PR/milestone operations, use scripts (NOT raw tea/gh):
- `~/.mosaic/rails/git/issue-view.sh -i {N}` - `~/.config/mosaic/rails/git/issue-view.sh -i {N}`
- `~/.mosaic/rails/git/pr-create.sh -t "Title" -b "Desc" -B develop` - `~/.config/mosaic/rails/git/pr-create.sh -t "Title" -b "Desc" -B develop`
Standard git commands (pull, commit, push, checkout) are fine. Standard git commands (pull, commit, push, checkout) are fine.
@@ -706,7 +706,7 @@ Next: MS-SEC-004
### Cross-Project Learnings ### Cross-Project Learnings
Universal heuristics are maintained in `~/.mosaic/guides/orchestrator-learnings.md`. Universal heuristics are maintained in `~/.config/mosaic/guides/orchestrator-learnings.md`.
After completing a milestone, review variance patterns and propose updates to the universal guide. After completing a milestone, review variance patterns and propose updates to the universal guide.
--- ---
@@ -858,7 +858,7 @@ Remediate findings from the codebase review.
- Task prefix: {PREFIX} (e.g., MS, UC) - Task prefix: {PREFIX} (e.g., MS, UC)
## Protocol ## Protocol
Read ~/.mosaic/guides/orchestrator.md for full instructions. Read ~/.config/mosaic/guides/orchestrator.md for full instructions.
## Start ## Start
Bootstrap from the review report, then execute until complete. Bootstrap from the review report, then execute until complete.

View File

@@ -1,7 +1,7 @@
# QA & Testing Guide # QA & Testing Guide
## Before Starting ## Before Starting
1. Check assigned issue: `~/.mosaic/rails/git/issue-list.sh -a @me` 1. Check assigned issue: `~/.config/mosaic/rails/git/issue-list.sh -a @me`
2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md` 2. Create scratchpad: `docs/scratchpads/{issue-number}-{short-name}.md`
3. Review existing test structure and patterns 3. Review existing test structure and patterns

View File

@@ -2,7 +2,7 @@
set -euo pipefail set -euo pipefail
SOURCE_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" SOURCE_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
TARGET_DIR="${MOSAIC_HOME:-$HOME/.mosaic}" TARGET_DIR="${MOSAIC_HOME:-$HOME/.config/mosaic}"
mkdir -p "$TARGET_DIR" mkdir -p "$TARGET_DIR"
@@ -39,7 +39,7 @@ fi
echo "[mosaic-install] Running health audit" echo "[mosaic-install] Running health audit"
if ! "$TARGET_DIR/bin/mosaic-doctor"; then if ! "$TARGET_DIR/bin/mosaic-doctor"; then
echo "[mosaic-install] WARNING: doctor reported issues (run ~/.mosaic/bin/mosaic-doctor --fail-on-warn)" >&2 echo "[mosaic-install] WARNING: doctor reported issues (run ~/.config/mosaic/bin/mosaic-doctor --fail-on-warn)" >&2
fi fi
echo "[mosaic-install] Add to PATH: export PATH=\"$TARGET_DIR/bin:$PATH\"" echo "[mosaic-install] Add to PATH: export PATH=\"$TARGET_DIR/bin:$PATH\""

View File

@@ -10,12 +10,12 @@ Profiles are runtime-neutral context packs that can be consumed by any agent run
## Runtime Split ## Runtime Split
- Runtime-neutral content belongs here under `~/.mosaic/profiles`. - Runtime-neutral content belongs here under `~/.config/mosaic/profiles`.
- Runtime-specific settings belong under `~/.mosaic/runtime/<runtime>/...`. - Runtime-specific settings belong under `~/.config/mosaic/runtime/<runtime>/...`.
Current runtime overlay example: Current runtime overlay example:
- `~/.mosaic/runtime/claude/settings-overlays/jarvis-ralph.json` - `~/.config/mosaic/runtime/claude/settings-overlays/jarvis-ralph.json`
## Claude Compatibility ## Claude Compatibility

View File

@@ -105,7 +105,7 @@ check_agents_md() {
# Check conditional loading/context (references guides or conditional section) # Check conditional loading/context (references guides or conditional section)
check_conditional_loading() { check_conditional_loading() {
local claude_md="$1/CLAUDE.md" local claude_md="$1/CLAUDE.md"
[[ -f "$claude_md" ]] && grep -qi "agent-guides\|~/.mosaic/guides\|conditional.*loading\|conditional.*documentation\|conditional.*context" "$claude_md" 2>/dev/null [[ -f "$claude_md" ]] && grep -qi "agent-guides\|~/.config/mosaic/guides\|conditional.*loading\|conditional.*documentation\|conditional.*context" "$claude_md" 2>/dev/null
} }
# Check quality gates # Check quality gates
@@ -214,9 +214,9 @@ JSONEOF
if $FIX_HINT && ! $JSON_OUTPUT; then if $FIX_HINT && ! $JSON_OUTPUT; then
if [[ "$has_claude" == "MISS" || "$has_agents" == "MISS" ]]; then if [[ "$has_claude" == "MISS" || "$has_agents" == "MISS" ]]; then
echo " ${DIM}Fix: ~/.mosaic/rails/bootstrap/init-project.sh --name \"$name\" --type auto${NC}" echo " ${DIM}Fix: ~/.config/mosaic/rails/bootstrap/init-project.sh --name \"$name\" --type auto${NC}"
elif [[ "$has_guides" == "MISS" ]]; then elif [[ "$has_guides" == "MISS" ]]; then
echo " ${DIM}Fix: ~/.mosaic/rails/bootstrap/agent-upgrade.sh $dir --section conditional-loading${NC}" echo " ${DIM}Fix: ~/.config/mosaic/rails/bootstrap/agent-upgrade.sh $dir --section conditional-loading${NC}"
fi fi
fi fi

View File

@@ -18,8 +18,8 @@ set -euo pipefail
# Defaults # Defaults
SRC_DIR="$HOME/src" SRC_DIR="$HOME/src"
FRAGMENTS_DIR="$HOME/.mosaic/templates/agent/fragments" FRAGMENTS_DIR="$HOME/.config/mosaic/templates/agent/fragments"
TEMPLATES_DIR="$HOME/.mosaic/templates/agent" TEMPLATES_DIR="$HOME/.config/mosaic/templates/agent"
DRY_RUN=false DRY_RUN=false
ALL_PROJECTS=false ALL_PROJECTS=false
TARGET_PATH="" TARGET_PATH=""
@@ -135,7 +135,7 @@ inject_fragment() {
# Determine detection pattern for this fragment # Determine detection pattern for this fragment
local detect_pattern local detect_pattern
case "$fragment_name" in case "$fragment_name" in
conditional-loading) detect_pattern="agent-guides\|~/.mosaic/guides\|Conditional.*Loading\|Conditional.*Documentation\|Conditional.*Context" ;; conditional-loading) detect_pattern="agent-guides\|~/.config/mosaic/guides\|Conditional.*Loading\|Conditional.*Documentation\|Conditional.*Context" ;;
commit-format) detect_pattern="<type>.*#issue\|Types:.*feat.*fix" ;; commit-format) detect_pattern="<type>.*#issue\|Types:.*feat.*fix" ;;
secrets) detect_pattern="NEVER hardcode secrets\|\.env.example.*committed" ;; secrets) detect_pattern="NEVER hardcode secrets\|\.env.example.*committed" ;;
multi-agent) detect_pattern="Multi-Agent Coordination\|pull --rebase.*before" ;; multi-agent) detect_pattern="Multi-Agent Coordination\|pull --rebase.*before" ;;

View File

@@ -8,8 +8,8 @@
set -e set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
TEMPLATE_DIR="$HOME/.mosaic/templates/agent" TEMPLATE_DIR="$HOME/.config/mosaic/templates/agent"
GIT_SCRIPT_DIR="$HOME/.mosaic/rails/git" GIT_SCRIPT_DIR="$HOME/.config/mosaic/rails/git"
# Defaults # Defaults
PROJECT_NAME="" PROJECT_NAME=""
@@ -373,7 +373,7 @@ echo "Created docs/scratchpads/, docs/reports/, docs/templates/"
# Set up CI/CD pipeline # Set up CI/CD pipeline
if [[ "$SKIP_CI" != true ]]; then if [[ "$SKIP_CI" != true ]]; then
CODEX_DIR="$HOME/.mosaic/rails/codex" CODEX_DIR="$HOME/.config/mosaic/rails/codex"
if [[ -d "$CODEX_DIR/woodpecker" ]]; then if [[ -d "$CODEX_DIR/woodpecker" ]]; then
mkdir -p .woodpecker/schemas mkdir -p .woodpecker/schemas
cp "$CODEX_DIR/woodpecker/codex-review.yml" .woodpecker/ cp "$CODEX_DIR/woodpecker/codex-review.yml" .woodpecker/
@@ -386,7 +386,7 @@ fi
# Generate Docker build/push/link pipeline steps # Generate Docker build/push/link pipeline steps
if [[ "$CICD_DOCKER" == true ]]; then if [[ "$CICD_DOCKER" == true ]]; then
CICD_SCRIPT="$HOME/.mosaic/rails/cicd/generate-docker-steps.sh" CICD_SCRIPT="$HOME/.config/mosaic/rails/cicd/generate-docker-steps.sh"
if [[ -x "$CICD_SCRIPT" ]]; then if [[ -x "$CICD_SCRIPT" ]]; then
# Parse org and repo from git remote # Parse org and repo from git remote
CICD_REGISTRY="" CICD_REGISTRY=""

View File

@@ -7,7 +7,7 @@
set -e set -e
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
GIT_SCRIPT_DIR="$HOME/.mosaic/rails/git" GIT_SCRIPT_DIR="$HOME/.config/mosaic/rails/git"
source "$GIT_SCRIPT_DIR/detect-platform.sh" source "$GIT_SCRIPT_DIR/detect-platform.sh"
SKIP_MILESTONE=false SKIP_MILESTONE=false

View File

@@ -50,45 +50,45 @@ Security vulnerability review focusing on:
```bash ```bash
# Code review # Code review
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review # Security review
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
### Review a Pull Request ### Review a Pull Request
```bash ```bash
# Review and post findings as a PR comment # Review and post findings as a PR comment
~/.mosaic/rails/codex/codex-code-review.sh -n 42 ~/.config/mosaic/rails/codex/codex-code-review.sh -n 42
# Security review and post to PR # Security review and post to PR
~/.mosaic/rails/codex/codex-security-review.sh -n 42 ~/.config/mosaic/rails/codex/codex-security-review.sh -n 42
``` ```
### Review Against Base Branch ### Review Against Base Branch
```bash ```bash
# Code review changes vs main # Code review changes vs main
~/.mosaic/rails/codex/codex-code-review.sh -b main ~/.config/mosaic/rails/codex/codex-code-review.sh -b main
# Security review changes vs develop # Security review changes vs develop
~/.mosaic/rails/codex/codex-security-review.sh -b develop ~/.config/mosaic/rails/codex/codex-security-review.sh -b develop
``` ```
### Review a Specific Commit ### Review a Specific Commit
```bash ```bash
~/.mosaic/rails/codex/codex-code-review.sh -c abc123f ~/.config/mosaic/rails/codex/codex-code-review.sh -c abc123f
~/.mosaic/rails/codex/codex-security-review.sh -c abc123f ~/.config/mosaic/rails/codex/codex-security-review.sh -c abc123f
``` ```
### Save Results to File ### Save Results to File
```bash ```bash
# Save JSON output # Save JSON output
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted -o review-results.json ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted -o review-results.json
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted -o security-results.json ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted -o security-results.json
``` ```
## Options ## Options
@@ -113,12 +113,12 @@ Automated PR reviews in CI pipelines.
1. **Copy the pipeline template to your repo:** 1. **Copy the pipeline template to your repo:**
```bash ```bash
cp ~/.mosaic/rails/codex/woodpecker/codex-review.yml your-repo/.woodpecker/ cp ~/.config/mosaic/rails/codex/woodpecker/codex-review.yml your-repo/.woodpecker/
``` ```
2. **Copy the schemas directory:** 2. **Copy the schemas directory:**
```bash ```bash
cp -r ~/.mosaic/rails/codex/schemas your-repo/.woodpecker/ cp -r ~/.config/mosaic/rails/codex/schemas your-repo/.woodpecker/
``` ```
3. **Add Codex API key to Woodpecker:** 3. **Add Codex API key to Woodpecker:**
@@ -203,7 +203,7 @@ Automated PR reviews in CI pipelines.
## Platform Support ## Platform Support
Works with both **GitHub** and **Gitea** via the shared `~/.mosaic/rails/git/` infrastructure: Works with both **GitHub** and **Gitea** via the shared `~/.config/mosaic/rails/git/` infrastructure:
- Auto-detects platform from git remote - Auto-detects platform from git remote
- Posts PR comments using `gh` (GitHub) or `tea` (Gitea) - Posts PR comments using `gh` (GitHub) or `tea` (Gitea)
- Unified interface across both platforms - Unified interface across both platforms
@@ -260,6 +260,6 @@ For best results, use `gpt-5.2-codex` or newer for strongest review accuracy.
## See Also ## See Also
- `~/.mosaic/guides/code-review.md` — Manual code review checklist - `~/.config/mosaic/guides/code-review.md` — Manual code review checklist
- `~/.mosaic/rails/git/` — Git helper scripts (issue/PR management) - `~/.config/mosaic/rails/git/` — Git helper scripts (issue/PR management)
- OpenAI Codex CLI docs: https://developers.openai.com/codex/cli/ - OpenAI Codex CLI docs: https://developers.openai.com/codex/cli/

View File

@@ -35,26 +35,26 @@ The controller expects this layout in each bootstrapped repo:
From a bootstrapped repo: From a bootstrapped repo:
```bash ```bash
~/.mosaic/bin/mosaic-orchestrator-matrix-cycle ~/.config/mosaic/bin/mosaic-orchestrator-matrix-cycle
~/.mosaic/bin/mosaic-orchestrator-run --once ~/.config/mosaic/bin/mosaic-orchestrator-run --once
``` ```
Continuous loop: Continuous loop:
```bash ```bash
~/.mosaic/bin/mosaic-orchestrator-run --poll-sec 10 ~/.config/mosaic/bin/mosaic-orchestrator-run --poll-sec 10
``` ```
Publish new orchestrator events to Matrix: Publish new orchestrator events to Matrix:
```bash ```bash
~/.mosaic/bin/mosaic-orchestrator-matrix-publish ~/.config/mosaic/bin/mosaic-orchestrator-matrix-publish
``` ```
Consume Matrix task messages into `tasks.json`: Consume Matrix task messages into `tasks.json`:
```bash ```bash
~/.mosaic/bin/mosaic-orchestrator-matrix-consume ~/.config/mosaic/bin/mosaic-orchestrator-matrix-consume
``` ```
## Matrix Note ## Matrix Note

View File

@@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
# Universal QA hook handler with robust error handling # Universal QA hook handler with robust error handling
# Location: ~/.mosaic/rails/qa/qa-hook-handler.sh # Location: ~/.config/mosaic/rails/qa/qa-hook-handler.sh
# Don't exit on unset variables initially to handle missing params gracefully # Don't exit on unset variables initially to handle missing params gracefully
set -eo pipefail set -eo pipefail

View File

@@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
# QA Hook handler that reads from stdin # QA Hook handler that reads from stdin
# Location: ~/.mosaic/rails/qa/qa-hook-stdin.sh # Location: ~/.config/mosaic/rails/qa/qa-hook-stdin.sh
set -eo pipefail set -eo pipefail
@@ -51,9 +51,9 @@ if ! [[ "$FILE_PATH" =~ \.(ts|tsx|js|jsx|mjs|cjs)$ ]]; then
fi fi
# Call the main QA handler with extracted parameters # Call the main QA handler with extracted parameters
if [ -f ~/.mosaic/rails/qa/qa-hook-handler.sh ]; then if [ -f ~/.config/mosaic/rails/qa/qa-hook-handler.sh ]; then
echo "[$(date '+%Y-%m-%d %H:%M:%S')] Calling QA handler for $FILE_PATH" >> "$LOG_FILE" echo "[$(date '+%Y-%m-%d %H:%M:%S')] Calling QA handler for $FILE_PATH" >> "$LOG_FILE"
~/.mosaic/rails/qa/qa-hook-handler.sh "$TOOL_NAME" "$FILE_PATH" 2>&1 | tee -a "$LOG_FILE" ~/.config/mosaic/rails/qa/qa-hook-handler.sh "$TOOL_NAME" "$FILE_PATH" 2>&1 | tee -a "$LOG_FILE"
else else
echo "[$(date '+%Y-%m-%d %H:%M:%S')] [ERROR] QA handler script not found" >> "$LOG_FILE" echo "[$(date '+%Y-%m-%d %H:%M:%S')] [ERROR] QA handler script not found" >> "$LOG_FILE"
fi fi

View File

@@ -13,7 +13,7 @@ echo "[$(date '+%Y-%m-%d %H:%M:%S')] Hook wrapper called: tool=$TOOL_NAME file=$
# Call the actual QA handler if we have a file # Call the actual QA handler if we have a file
if [ -n "$FILE_PATH" ]; then if [ -n "$FILE_PATH" ]; then
~/.mosaic/rails/qa/qa-hook-handler.sh "$TOOL_NAME" "$FILE_PATH" ~/.config/mosaic/rails/qa/qa-hook-handler.sh "$TOOL_NAME" "$FILE_PATH"
else else
echo "[$(date '+%Y-%m-%d %H:%M:%S')] No file path available for QA check" >> logs/qa-automation.log 2>/dev/null || true echo "[$(date '+%Y-%m-%d %H:%M:%S')] No file path available for QA check" >> logs/qa-automation.log 2>/dev/null || true
fi fi

View File

@@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
# Monitor QA queues with graceful handling of missing directories # Monitor QA queues with graceful handling of missing directories
# Location: ~/.mosaic/rails/qa/qa-queue-monitor.sh # Location: ~/.config/mosaic/rails/qa/qa-queue-monitor.sh
PROJECT_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || pwd) PROJECT_ROOT=$(git rev-parse --show-toplevel 2>/dev/null || pwd)

View File

@@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
# Universal remediation hook handler with error recovery # Universal remediation hook handler with error recovery
# Location: ~/.mosaic/rails/qa/remediation-hook-handler.sh # Location: ~/.config/mosaic/rails/qa/remediation-hook-handler.sh
set -euo pipefail set -euo pipefail

View File

@@ -19,7 +19,7 @@ Based on real-world validation of 50 issues in a production codebase:
### New Project ### New Project
```bash ```bash
# Apply template from Mosaic # Apply template from Mosaic
~/.mosaic/bin/mosaic-quality-apply --template typescript-node --target /path/to/project ~/.config/mosaic/bin/mosaic-quality-apply --template typescript-node --target /path/to/project
# Install dependencies # Install dependencies
cd /path/to/project cd /path/to/project
@@ -29,13 +29,13 @@ npm install
npx husky install npx husky install
# Verify enforcement is working # Verify enforcement is working
~/.mosaic/bin/mosaic-quality-verify --target /path/to/project ~/.config/mosaic/bin/mosaic-quality-verify --target /path/to/project
``` ```
### Existing Project ### Existing Project
```bash ```bash
# Same as above - works for new or existing projects # Same as above - works for new or existing projects
~/.mosaic/bin/mosaic-quality-apply --template typescript-node --target /path/to/existing-project ~/.config/mosaic/bin/mosaic-quality-apply --template typescript-node --target /path/to/existing-project
``` ```
## 🛡️ What You Get ## 🛡️ What You Get

View File

@@ -71,5 +71,5 @@ echo ""
echo "Next steps:" echo "Next steps:"
echo "1. Install dependencies: npm install" echo "1. Install dependencies: npm install"
echo "2. Initialize husky: npx husky install" echo "2. Initialize husky: npx husky install"
echo "3. Run verification: ~/.mosaic/bin/mosaic-quality-verify --target $TARGET_DIR" echo "3. Run verification: ~/.config/mosaic/bin/mosaic-quality-verify --target $TARGET_DIR"
echo "" echo ""

View File

@@ -1,10 +1,10 @@
# Mosaic Universal Standards (Machine-Wide) # Mosaic Universal Standards (Machine-Wide)
Before applying any runtime-specific guidance in this file, load and apply: Before applying any runtime-specific guidance in this file, load and apply:
- `~/.mosaic/STANDARDS.md` - `~/.config/mosaic/STANDARDS.md`
- project-local `AGENTS.md` - project-local `AGENTS.md`
`~/.mosaic` is the canonical cross-agent standards layer. This `CLAUDE.md` is an adapter layer for Claude-specific capabilities only. `~/.config/mosaic` is the canonical cross-agent standards layer. This `CLAUDE.md` is an adapter layer for Claude-specific capabilities only.
--- ---
@@ -17,11 +17,11 @@ Before applying any runtime-specific guidance in this file, load and apply:
## Skills System ## Skills System
**Skills are available in `~/.mosaic/skills/`.** Skills are instruction packages that provide domain expertise from `mosaic/agent-skills` plus local Mosaic skills. **Skills are available in `~/.config/mosaic/skills/`.** Skills are instruction packages that provide domain expertise from `mosaic/agent-skills` plus local Mosaic skills.
**Load a skill by reading its SKILL.md:** **Load a skill by reading its SKILL.md:**
``` ```
Read ~/.mosaic/skills/<skill-name>/SKILL.md Read ~/.config/mosaic/skills/<skill-name>/SKILL.md
``` ```
### Skill Dispatch Table — Load the right skills for your task ### Skill Dispatch Table — Load the right skills for your task
@@ -66,7 +66,7 @@ Read ~/.mosaic/skills/<skill-name>/SKILL.md
When spawning workers via `claude -p`, include skill loading in the kickstart: When spawning workers via `claude -p`, include skill loading in the kickstart:
```bash ```bash
claude -p "Read ~/.mosaic/skills/nestjs-best-practices/SKILL.md then implement..." claude -p "Read ~/.config/mosaic/skills/nestjs-best-practices/SKILL.md then implement..."
``` ```
For Ralph prd.json stories, add a `skills` field: For Ralph prd.json stories, add a `skills` field:
@@ -118,7 +118,7 @@ claude -p "Implement US-001 from prd.json following Ralph pattern"
2. Convert to Ralph: `Load the ralph skill and convert tasks/prd-[name].md to prd.json` 2. Convert to Ralph: `Load the ralph skill and convert tasks/prd-[name].md to prd.json`
3. Run Ralph: `./scripts/ralph/ralph.sh` 3. Run Ralph: `./scripts/ralph/ralph.sh`
**For full Ralph guide:** `~/.mosaic/guides/ralph-autonomous.md` **For full Ralph guide:** `~/.config/mosaic/guides/ralph-autonomous.md`
## AGENTS.md Pattern ## AGENTS.md Pattern
@@ -148,40 +148,40 @@ When starting work on a **new project** that lacks `CLAUDE.md` or `AGENTS.md`, b
```bash ```bash
# Automated (recommended) # Automated (recommended)
~/.mosaic/rails/bootstrap/init-project.sh --name "Project Name" --type auto ~/.config/mosaic/rails/bootstrap/init-project.sh --name "Project Name" --type auto
# Or manually with templates # Or manually with templates
export PROJECT_NAME="Project Name" PROJECT_DESCRIPTION="What it does" TASK_PREFIX="PN" export PROJECT_NAME="Project Name" PROJECT_DESCRIPTION="What it does" TASK_PREFIX="PN"
envsubst < ~/.mosaic/templates/agent/CLAUDE.md.template > CLAUDE.md envsubst < ~/.config/mosaic/templates/agent/CLAUDE.md.template > CLAUDE.md
envsubst < ~/.mosaic/templates/agent/AGENTS.md.template > AGENTS.md envsubst < ~/.config/mosaic/templates/agent/AGENTS.md.template > AGENTS.md
``` ```
**Available project types:** `nestjs-nextjs`, `django`, `typescript`, `python-fastapi`, `python-library`, `generic` (auto-detected from project files). **Available project types:** `nestjs-nextjs`, `django`, `typescript`, `python-fastapi`, `python-library`, `generic` (auto-detected from project files).
**Templates:** `~/.mosaic/templates/agent/` (generic) and `~/.mosaic/templates/agent/projects/<type>/` (tech-stack specific). **Templates:** `~/.config/mosaic/templates/agent/` (generic) and `~/.config/mosaic/templates/agent/projects/<type>/` (tech-stack specific).
**Fragments:** `~/.mosaic/templates/agent/fragments/` — Reusable sections (conditional-loading, commit-format, secrets, multi-agent, code-review). **Fragments:** `~/.config/mosaic/templates/agent/fragments/` — Reusable sections (conditional-loading, commit-format, secrets, multi-agent, code-review).
**Full guide:** `~/.mosaic/guides/bootstrap.md` **Full guide:** `~/.config/mosaic/guides/bootstrap.md`
### Agent Configuration Health ### Agent Configuration Health
```bash ```bash
# Audit all projects for missing CLAUDE.md, AGENTS.md, agent-guide references # Audit all projects for missing CLAUDE.md, AGENTS.md, agent-guide references
~/.mosaic/rails/bootstrap/agent-lint.sh ~/.config/mosaic/rails/bootstrap/agent-lint.sh
# Audit with fix suggestions # Audit with fix suggestions
~/.mosaic/rails/bootstrap/agent-lint.sh --verbose --fix-hint ~/.config/mosaic/rails/bootstrap/agent-lint.sh --verbose --fix-hint
# Non-destructively upgrade existing projects (inject missing sections) # Non-destructively upgrade existing projects (inject missing sections)
~/.mosaic/rails/bootstrap/agent-upgrade.sh --all --dry-run # Preview ~/.config/mosaic/rails/bootstrap/agent-upgrade.sh --all --dry-run # Preview
~/.mosaic/rails/bootstrap/agent-upgrade.sh --all # Apply ~/.config/mosaic/rails/bootstrap/agent-upgrade.sh --all # Apply
# Upgrade a single project # Upgrade a single project
~/.mosaic/rails/bootstrap/agent-upgrade.sh ~/src/my-project ~/.config/mosaic/rails/bootstrap/agent-upgrade.sh ~/src/my-project
``` ```
**Spec:** `~/.mosaic/templates/agent/SPEC.md` — Defines Tier 1/2/3 requirements for well-configured projects. **Spec:** `~/.config/mosaic/templates/agent/SPEC.md` — Defines Tier 1/2/3 requirements for well-configured projects.
## Issue Tracking (Git-Based) ## Issue Tracking (Git-Based)
@@ -210,7 +210,7 @@ Use consistent labels across projects:
- Post-release: `X.0.0` for breaking changes - Post-release: `X.0.0` for breaking changes
### Git Scripts (PREFERRED for Gitea/GitHub operations) ### Git Scripts (PREFERRED for Gitea/GitHub operations)
Cross-platform helpers at `~/.mosaic/rails/git/` (work with both Gitea and GitHub): Cross-platform helpers at `~/.config/mosaic/rails/git/` (work with both Gitea and GitHub):
**Why use these scripts?** **Why use these scripts?**
- ✅ Auto-detect platform (Gitea vs GitHub) - ✅ Auto-detect platform (Gitea vs GitHub)
@@ -220,37 +220,37 @@ Cross-platform helpers at `~/.mosaic/rails/git/` (work with both Gitea and GitHu
**Issues:** **Issues:**
```bash ```bash
~/.mosaic/rails/git/issue-create.sh -t "Title" -l "label" -m "0.2.0" ~/.config/mosaic/rails/git/issue-create.sh -t "Title" -l "label" -m "0.2.0"
~/.mosaic/rails/git/issue-list.sh -s open -l "bug" ~/.config/mosaic/rails/git/issue-list.sh -s open -l "bug"
~/.mosaic/rails/git/issue-list.sh -m "M6-AgentOrchestration" # Works with milestone names! ~/.config/mosaic/rails/git/issue-list.sh -m "M6-AgentOrchestration" # Works with milestone names!
~/.mosaic/rails/git/issue-view.sh -i 42 # View issue details ~/.config/mosaic/rails/git/issue-view.sh -i 42 # View issue details
~/.mosaic/rails/git/issue-edit.sh -i 42 -t "New Title" -l "labels" ~/.config/mosaic/rails/git/issue-edit.sh -i 42 -t "New Title" -l "labels"
~/.mosaic/rails/git/issue-assign.sh -i 42 -a "username" ~/.config/mosaic/rails/git/issue-assign.sh -i 42 -a "username"
~/.mosaic/rails/git/issue-comment.sh -i 42 -c "Comment text" ~/.config/mosaic/rails/git/issue-comment.sh -i 42 -c "Comment text"
~/.mosaic/rails/git/issue-close.sh -i 42 [-c "Closing comment"] ~/.config/mosaic/rails/git/issue-close.sh -i 42 [-c "Closing comment"]
~/.mosaic/rails/git/issue-reopen.sh -i 42 [-c "Reopening reason"] ~/.config/mosaic/rails/git/issue-reopen.sh -i 42 [-c "Reopening reason"]
``` ```
**Pull Requests:** **Pull Requests:**
```bash ```bash
~/.mosaic/rails/git/pr-create.sh -t "Title" -b "Description" -i 42 ~/.config/mosaic/rails/git/pr-create.sh -t "Title" -b "Description" -i 42
~/.mosaic/rails/git/pr-create.sh -t "Title" -B main -H feature-branch ~/.config/mosaic/rails/git/pr-create.sh -t "Title" -B main -H feature-branch
~/.mosaic/rails/git/pr-list.sh -s open ~/.config/mosaic/rails/git/pr-list.sh -s open
~/.mosaic/rails/git/pr-view.sh -n 42 # View PR details ~/.config/mosaic/rails/git/pr-view.sh -n 42 # View PR details
~/.mosaic/rails/git/pr-review.sh -n 42 -a approve [-c "LGTM"] ~/.config/mosaic/rails/git/pr-review.sh -n 42 -a approve [-c "LGTM"]
~/.mosaic/rails/git/pr-review.sh -n 42 -a request-changes -c "Fix X" ~/.config/mosaic/rails/git/pr-review.sh -n 42 -a request-changes -c "Fix X"
~/.mosaic/rails/git/pr-merge.sh -n 42 -m squash -d ~/.config/mosaic/rails/git/pr-merge.sh -n 42 -m squash -d
~/.mosaic/rails/git/pr-close.sh -n 42 [-c "Closing reason"] ~/.config/mosaic/rails/git/pr-close.sh -n 42 [-c "Closing reason"]
~/.mosaic/rails/git/pr-diff.sh -n 42 [-o diff.patch] # Get PR diff ~/.config/mosaic/rails/git/pr-diff.sh -n 42 [-o diff.patch] # Get PR diff
~/.mosaic/rails/git/pr-metadata.sh -n 42 [-o metadata.json] # Get PR metadata as JSON ~/.config/mosaic/rails/git/pr-metadata.sh -n 42 [-o metadata.json] # Get PR metadata as JSON
``` ```
**Milestones:** **Milestones:**
```bash ```bash
~/.mosaic/rails/git/milestone-create.sh -t "0.2.0" -d "Description" ~/.config/mosaic/rails/git/milestone-create.sh -t "0.2.0" -d "Description"
~/.mosaic/rails/git/milestone-create.sh --list ~/.config/mosaic/rails/git/milestone-create.sh --list
~/.mosaic/rails/git/milestone-list.sh [-s open|closed|all] ~/.config/mosaic/rails/git/milestone-list.sh [-s open|closed|all]
~/.mosaic/rails/git/milestone-close.sh -t "0.2.0" ~/.config/mosaic/rails/git/milestone-close.sh -t "0.2.0"
``` ```
**NOTE:** These scripts handle the Gitea `--milestones` (plural) syntax automatically. Always prefer these over raw `tea` or `gh` commands. **NOTE:** These scripts handle the Gitea `--milestones` (plural) syntax automatically. Always prefer these over raw `tea` or `gh` commands.
@@ -303,7 +303,7 @@ woodpecker secret rm <owner/repo> -n KEY # Delete secret
**Setup command:** `woodpecker setup --server https://ci.mosaicstack.dev --token "YOUR_TOKEN"` **Setup command:** `woodpecker setup --server https://ci.mosaicstack.dev --token "YOUR_TOKEN"`
### Portainer Scripts ### Portainer Scripts
CLI tools for managing Portainer stacks at `~/.mosaic/rails/portainer/`. CLI tools for managing Portainer stacks at `~/.config/mosaic/rails/portainer/`.
**Setup:** **Setup:**
```bash ```bash
@@ -345,9 +345,9 @@ endpoint-list.sh -f json # JSON format
**Common Workflow (CI/CD redeploy):** **Common Workflow (CI/CD redeploy):**
```bash ```bash
~/.mosaic/rails/portainer/stack-redeploy.sh -n myapp -p && \ ~/.config/mosaic/rails/portainer/stack-redeploy.sh -n myapp -p && \
~/.mosaic/rails/portainer/stack-status.sh -n myapp && \ ~/.config/mosaic/rails/portainer/stack-status.sh -n myapp && \
~/.mosaic/rails/portainer/stack-logs.sh -n myapp -s api -t 50 ~/.config/mosaic/rails/portainer/stack-logs.sh -n myapp -s api -t 50
``` ```
### Git Worktrees ### Git Worktrees
@@ -398,7 +398,7 @@ git worktree remove ../my-app_worktrees/42-fix-login
- Never disable lint rules (`eslint-disable`, `noqa`, `nolint`) - Never disable lint rules (`eslint-disable`, `noqa`, `nolint`)
- Never leave warnings — warnings are errors you haven't fixed yet - Never leave warnings — warnings are errors you haven't fixed yet
- If you touched a file, you own its lint violations (Campsite Rule) - If you touched a file, you own its lint violations (Campsite Rule)
- If unsure what linter the project uses, read the `lint` skill: `~/.mosaic/skills/lint/SKILL.md` - If unsure what linter the project uses, read the `lint` skill: `~/.config/mosaic/skills/lint/SKILL.md`
### Code Style ### Code Style
Follow [Google Style Guides](https://github.com/google/styleguide) for all languages. Follow [Google Style Guides](https://github.com/google/styleguide) for all languages.
@@ -443,30 +443,30 @@ When working on issue #N, create `docs/scratchpads/N-short-name.md`:
| Task Type | Guide | | Task Type | Guide |
|-----------|-------| |-----------|-------|
| Bootstrapping a new project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping a new project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous task completion | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous task completion | `~/.config/mosaic/guides/orchestrator.md` |
| Ralph autonomous development | `~/.mosaic/guides/ralph-autonomous.md` | | Ralph autonomous development | `~/.config/mosaic/guides/ralph-autonomous.md` |
| Frontend development | `~/.mosaic/guides/frontend.md` | | Frontend development | `~/.config/mosaic/guides/frontend.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| Authentication/Authorization | `~/.mosaic/guides/authentication.md` | | Authentication/Authorization | `~/.config/mosaic/guides/authentication.md` |
| CI/CD pipelines & Docker builds | `~/.mosaic/guides/ci-cd-pipelines.md` | | CI/CD pipelines & Docker builds | `~/.config/mosaic/guides/ci-cd-pipelines.md` |
| Infrastructure/DevOps | `~/.mosaic/guides/infrastructure.md` | | Infrastructure/DevOps | `~/.config/mosaic/guides/infrastructure.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
| Secrets management | See section below | | Secrets management | See section below |
**Project-specific skills:** **Project-specific skills:**
| Project | Skill | | Project | Skill |
|---------|-------| |---------|-------|
| jetrich/jarvis | `~/.mosaic/skills/jarvis/SKILL.md` | | jetrich/jarvis | `~/.config/mosaic/skills/jarvis/SKILL.md` |
## Secrets Management ## Secrets Management
**NEVER hardcode secrets in the codebase.** Choose the appropriate method based on your environment. **NEVER hardcode secrets in the codebase.** Choose the appropriate method based on your environment.
### If Using Vault ### If Using Vault
See `~/.mosaic/guides/vault-secrets.md` for the canonical structure and rules. See `~/.config/mosaic/guides/vault-secrets.md` for the canonical structure and rules.
Quick reference: Quick reference:
``` ```

View File

@@ -7,7 +7,7 @@
"hooks": [ "hooks": [
{ {
"type": "command", "type": "command",
"command": "~/.mosaic/rails/qa/qa-hook-stdin.sh", "command": "~/.config/mosaic/rails/qa/qa-hook-stdin.sh",
"timeout": 60 "timeout": 60
} }
] ]

View File

@@ -1,7 +1,7 @@
# Mosaic Runtime Adapter — OpenCode # Mosaic Runtime Adapter — OpenCode
Load and apply in this order: Load and apply in this order:
1. `~/.mosaic/STANDARDS.md` 1. `~/.config/mosaic/STANDARDS.md`
2. repo-local `AGENTS.md` (and `SOUL.md` when present) 2. repo-local `AGENTS.md` (and `SOUL.md` when present)
This file is an OpenCode adapter layer. It does not replace project guidance. This file is an OpenCode adapter layer. It does not replace project guidance.
@@ -10,19 +10,19 @@ This file is an OpenCode adapter layer. It does not replace project guidance.
- OpenCode sessions may not expose a native subagent/background task primitive in all deployments. - OpenCode sessions may not expose a native subagent/background task primitive in all deployments.
- When native subagent delegation is unavailable, use Mosaic's deterministic orchestrator rail: - When native subagent delegation is unavailable, use Mosaic's deterministic orchestrator rail:
- `~/.mosaic/bin/mosaic-orchestrator-matrix-cycle` - `~/.config/mosaic/bin/mosaic-orchestrator-matrix-cycle`
- Keep repo task tracking in `docs/tasks.md` as the canonical human-readable state. - Keep repo task tracking in `docs/tasks.md` as the canonical human-readable state.
- Keep machine transport/controller state in `.mosaic/orchestrator/`. - Keep machine transport/controller state in `.mosaic/orchestrator/`.
## Fallback Delegation Mode (No Native Subagents) ## Fallback Delegation Mode (No Native Subagents)
1. Bootstrap repo if needed: 1. Bootstrap repo if needed:
- `~/.mosaic/bin/mosaic-bootstrap-repo /path/to/repo` - `~/.config/mosaic/bin/mosaic-bootstrap-repo /path/to/repo`
2. Configure `.mosaic/orchestrator/config.json`: 2. Configure `.mosaic/orchestrator/config.json`:
- set `"enabled": true` - set `"enabled": true`
- set `"worker.command_template"` to your OpenCode worker command - set `"worker.command_template"` to your OpenCode worker command
3. Queue work items in `.mosaic/orchestrator/tasks.json` (or via Matrix command ingestion). 3. Queue work items in `.mosaic/orchestrator/tasks.json` (or via Matrix command ingestion).
4. Run deterministic ticks: 4. Run deterministic ticks:
- `~/.mosaic/bin/mosaic-orchestrator-matrix-cycle` - `~/.config/mosaic/bin/mosaic-orchestrator-matrix-cycle`
This preserves rails enforcement (`quality_gates`) even without runtime-native subagent features. This preserves rails enforcement (`quality_gates`) even without runtime-native subagent features.

View File

@@ -7,7 +7,7 @@ description: Load machine-wide Mosaic standards and enforce the repository lifec
## Load Order ## Load Order
1. `~/.mosaic/STANDARDS.md` 1. `~/.config/mosaic/STANDARDS.md`
2. Repository `AGENTS.md` 2. Repository `AGENTS.md`
3. Repo-local `.mosaic/repo-hooks.sh` when present 3. Repo-local `.mosaic/repo-hooks.sh` when present
@@ -25,7 +25,7 @@ If wrappers are available, you may use:
## Enforcement Rules ## Enforcement Rules
- Treat `~/.mosaic` as canonical for shared guides, rails, profiles, and skills. - Treat `~/.config/mosaic` as canonical for shared guides, rails, profiles, and skills.
- Do not edit generated project views directly when the repo defines canonical data sources. - Do not edit generated project views directly when the repo defines canonical data sources.
- Pull/rebase before edits in shared repositories. - Pull/rebase before edits in shared repositories.
- Run project verification commands before claiming completion. - Run project verification commands before claiming completion.

View File

@@ -7,7 +7,7 @@ description: "Configure CI/CD Docker build, push, and package linking for a proj
Configure Docker build, registry push, and package linking for a Woodpecker CI pipeline using Kaniko and Gitea's container registry. Configure Docker build, registry push, and package linking for a Woodpecker CI pipeline using Kaniko and Gitea's container registry.
**Before starting:** Read `~/.mosaic/guides/ci-cd-pipelines.md` for deep background on the patterns used here. **Before starting:** Read `~/.config/mosaic/guides/ci-cd-pipelines.md` for deep background on the patterns used here.
**Reference implementation:** `~/src/mosaic-stack/.woodpecker.yml` **Reference implementation:** `~/src/mosaic-stack/.woodpecker.yml`
@@ -140,7 +140,7 @@ Ask these questions with lettered options (user can respond "1A, 2B, 3C"):
If the project's `.woodpecker.yml` doesn't already have a `kaniko_setup` anchor in its `variables:` section, add it: If the project's `.woodpecker.yml` doesn't already have a `kaniko_setup` anchor in its `variables:` section, add it:
```bash ```bash
~/.mosaic/rails/cicd/generate-docker-steps.sh --kaniko-setup-only --registry REGISTRY_HOST ~/.config/mosaic/rails/cicd/generate-docker-steps.sh --kaniko-setup-only --registry REGISTRY_HOST
``` ```
This outputs: This outputs:
@@ -158,7 +158,7 @@ Add this to the existing `variables:` block at the top of `.woodpecker.yml`.
Use the generator script with the user's answers: Use the generator script with the user's answers:
```bash ```bash
~/.mosaic/rails/cicd/generate-docker-steps.sh \ ~/.config/mosaic/rails/cicd/generate-docker-steps.sh \
--registry REGISTRY \ --registry REGISTRY \
--org ORG \ --org ORG \
--repo REPO \ --repo REPO \

View File

@@ -51,8 +51,8 @@ When completing an orchestrated task:
### Post-Coding Review ### Post-Coding Review
After implementing changes, the orchestrator will run: After implementing changes, the orchestrator will run:
1. **Codex code review** — `~/.mosaic/rails/codex/codex-code-review.sh --uncommitted` 1. **Codex code review** — `~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted`
2. **Codex security review** — `~/.mosaic/rails/codex/codex-security-review.sh --uncommitted` 2. **Codex security review** — `~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted`
3. If blockers/critical findings: remediation task created 3. If blockers/critical findings: remediation task created
4. If clean: task marked done 4. If clean: task marked done

View File

@@ -24,14 +24,14 @@ git push
| Task Type | Guide | | Task Type | Guide |
|-----------|-------| |-----------|-------|
| Bootstrapping this project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping this project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| Frontend development | `~/.mosaic/guides/frontend.md` | | Frontend development | `~/.config/mosaic/guides/frontend.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| Authentication/Authorization | `~/.mosaic/guides/authentication.md` | | Authentication/Authorization | `~/.config/mosaic/guides/authentication.md` |
| Infrastructure/DevOps | `~/.mosaic/guides/infrastructure.md` | | Infrastructure/DevOps | `~/.config/mosaic/guides/infrastructure.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
## Technology Stack ## Technology Stack
@@ -123,16 +123,16 @@ After completing code changes, run independent reviews:
```bash ```bash
# Code quality review (Codex) # Code quality review (Codex)
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review (Codex) # Security review (Codex)
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
**Fallback:** If Codex is unavailable, use Claude's built-in review skills. **Fallback:** If Codex is unavailable, use Claude's built-in review skills.
### Review Checklist ### Review Checklist
See `~/.mosaic/guides/code-review.md` for the full review checklist. See `~/.config/mosaic/guides/code-review.md` for the full review checklist.
## Secrets Management ## Secrets Management

View File

@@ -6,7 +6,7 @@
### Tier 1 (Required — blocks audit pass) ### Tier 1 (Required — blocks audit pass)
1. **Conditional Documentation Loading** — Table linking to `~/.mosaic/guides/` 1. **Conditional Documentation Loading** — Table linking to `~/.config/mosaic/guides/`
2. **Quality Gates** — Bash commands that must pass before commit (build, test, lint, typecheck) 2. **Quality Gates** — Bash commands that must pass before commit (build, test, lint, typecheck)
3. **Build/Test/Lint commands** — How to build, test, and lint the project 3. **Build/Test/Lint commands** — How to build, test, and lint the project
@@ -56,13 +56,13 @@ The `agent-lint.sh` tool checks for these markers:
|-------|---------------| |-------|---------------|
| CLAUDE.md exists | File present at project root | | CLAUDE.md exists | File present at project root |
| AGENTS.md exists | File present at project root | | AGENTS.md exists | File present at project root |
| Conditional context/loading | CLAUDE.md contains `~/.mosaic/guides` or `Conditional` + `Loading/Context` | | Conditional context/loading | CLAUDE.md contains `~/.config/mosaic/guides` or `Conditional` + `Loading/Context` |
| Quality gates | CLAUDE.md contains `Quality Gates` or quality commands (test, lint, typecheck) | | Quality gates | CLAUDE.md contains `Quality Gates` or quality commands (test, lint, typecheck) |
| Monorepo sub-agents | Each app/package dir with own manifest has AGENTS.md | | Monorepo sub-agents | Each app/package dir with own manifest has AGENTS.md |
## Fragment Sources ## Fragment Sources
Shared sections are maintained in `~/.mosaic/templates/agent/fragments/`: Shared sections are maintained in `~/.config/mosaic/templates/agent/fragments/`:
| Fragment | Injects Section | | Fragment | Injects Section |
|----------|----------------| |----------|----------------|

View File

@@ -4,11 +4,11 @@ After completing code changes, run independent reviews:
```bash ```bash
# Code quality review (Codex) # Code quality review (Codex)
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review (Codex) # Security review (Codex)
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
**Fallback:** If Codex is unavailable, use Claude's built-in review skills. **Fallback:** If Codex is unavailable, use Claude's built-in review skills.
See `~/.mosaic/guides/code-review.md` for the full review checklist. See `~/.config/mosaic/guides/code-review.md` for the full review checklist.

View File

@@ -4,14 +4,14 @@
| Task Type | Guide | | Task Type | Guide |
|-----------|-------| |-----------|-------|
| Bootstrapping a new project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping a new project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Ralph autonomous development | `~/.mosaic/guides/ralph-autonomous.md` | | Ralph autonomous development | `~/.config/mosaic/guides/ralph-autonomous.md` |
| Frontend development | `~/.mosaic/guides/frontend.md` | | Frontend development | `~/.config/mosaic/guides/frontend.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| TypeScript strict typing | `~/.mosaic/guides/typescript.md` | | TypeScript strict typing | `~/.config/mosaic/guides/typescript.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| Authentication/Authorization | `~/.mosaic/guides/authentication.md` | | Authentication/Authorization | `~/.config/mosaic/guides/authentication.md` |
| Infrastructure/DevOps | `~/.mosaic/guides/infrastructure.md` | | Infrastructure/DevOps | `~/.config/mosaic/guides/infrastructure.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
| Secrets management (Vault) | `~/.mosaic/guides/vault-secrets.md` | | Secrets management (Vault) | `~/.config/mosaic/guides/vault-secrets.md` |

View File

@@ -52,8 +52,8 @@ Use `${TASK_PREFIX}` for orchestrated tasks (e.g., `${TASK_PREFIX}-SEC-001`).
### Post-Coding Review ### Post-Coding Review
After implementing changes, the orchestrator will run: After implementing changes, the orchestrator will run:
1. **Codex code review** — `~/.mosaic/rails/codex/codex-code-review.sh --uncommitted` 1. **Codex code review** — `~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted`
2. **Codex security review** — `~/.mosaic/rails/codex/codex-security-review.sh --uncommitted` 2. **Codex security review** — `~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted`
3. If blockers/critical findings: remediation task created 3. If blockers/critical findings: remediation task created
4. If clean: task marked done 4. If clean: task marked done

View File

@@ -6,11 +6,11 @@
| When working on... | Load this guide | | When working on... | Load this guide |
|---|---| |---|---|
| Bootstrapping this project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping this project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
## Technology Stack ## Technology Stack
@@ -135,10 +135,10 @@ After completing code changes, run independent reviews:
```bash ```bash
# Code quality review (Codex) # Code quality review (Codex)
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review (Codex) # Security review (Codex)
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
## Issue Tracking ## Issue Tracking

View File

@@ -56,8 +56,8 @@ Use `${TASK_PREFIX}` for orchestrated tasks (e.g., `${TASK_PREFIX}-SEC-001`).
### Post-Coding Review ### Post-Coding Review
After implementing changes, the orchestrator will run: After implementing changes, the orchestrator will run:
1. **Codex code review** — `~/.mosaic/rails/codex/codex-code-review.sh --uncommitted` 1. **Codex code review** — `~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted`
2. **Codex security review** — `~/.mosaic/rails/codex/codex-security-review.sh --uncommitted` 2. **Codex security review** — `~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted`
3. If blockers/critical findings: remediation task created 3. If blockers/critical findings: remediation task created
4. If clean: task marked done 4. If clean: task marked done

View File

@@ -6,14 +6,14 @@
| When working on... | Load this guide | | When working on... | Load this guide |
|---|---| |---|---|
| Bootstrapping this project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping this project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Frontend development | `~/.mosaic/guides/frontend.md` | | Frontend development | `~/.config/mosaic/guides/frontend.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| TypeScript strict typing | `~/.mosaic/guides/typescript.md` | | TypeScript strict typing | `~/.config/mosaic/guides/typescript.md` |
| Authentication/Authorization | `~/.mosaic/guides/authentication.md` | | Authentication/Authorization | `~/.config/mosaic/guides/authentication.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
## Technology Stack ## Technology Stack
@@ -166,10 +166,10 @@ After completing code changes, run independent reviews:
```bash ```bash
# Code quality review (Codex) # Code quality review (Codex)
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review (Codex) # Security review (Codex)
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
## Issue Tracking ## Issue Tracking

View File

@@ -9,15 +9,15 @@
| Task Type | Guide | | Task Type | Guide |
|-----------|-------| |-----------|-------|
| Bootstrapping this project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping this project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Ralph autonomous development | `~/.mosaic/guides/ralph-autonomous.md` | | Ralph autonomous development | `~/.config/mosaic/guides/ralph-autonomous.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| Authentication/Authorization | `~/.mosaic/guides/authentication.md` | | Authentication/Authorization | `~/.config/mosaic/guides/authentication.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
| Infrastructure/DevOps | `~/.mosaic/guides/infrastructure.md` | | Infrastructure/DevOps | `~/.config/mosaic/guides/infrastructure.md` |
| Secrets management (Vault) | `~/.mosaic/guides/vault-secrets.md` | | Secrets management (Vault) | `~/.config/mosaic/guides/vault-secrets.md` |
## Technology Stack ## Technology Stack
@@ -112,11 +112,11 @@ Types: `feat`, `fix`, `docs`, `test`, `refactor`, `chore`
After completing code changes, run independent reviews: After completing code changes, run independent reviews:
```bash ```bash
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
See `~/.mosaic/guides/code-review.md` for the full review checklist. See `~/.config/mosaic/guides/code-review.md` for the full review checklist.
## Secrets Management ## Secrets Management

View File

@@ -9,12 +9,12 @@
| Task Type | Guide | | Task Type | Guide |
|-----------|-------| |-----------|-------|
| Bootstrapping this project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping this project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Ralph autonomous development | `~/.mosaic/guides/ralph-autonomous.md` | | Ralph autonomous development | `~/.config/mosaic/guides/ralph-autonomous.md` |
| Backend/API development | `~/.mosaic/guides/backend.md` | | Backend/API development | `~/.config/mosaic/guides/backend.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
## Technology Stack ## Technology Stack
@@ -102,11 +102,11 @@ Types: `feat`, `fix`, `docs`, `test`, `refactor`, `chore`
After completing code changes, run independent reviews: After completing code changes, run independent reviews:
```bash ```bash
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
See `~/.mosaic/guides/code-review.md` for the full review checklist. See `~/.config/mosaic/guides/code-review.md` for the full review checklist.
## Secrets Management ## Secrets Management

View File

@@ -6,7 +6,7 @@
## Codebase Patterns ## Codebase Patterns
- TypeScript strict mode enabled — no `any`, no implicit types - TypeScript strict mode enabled — no `any`, no implicit types
- See `~/.mosaic/guides/typescript.md` for mandatory TypeScript rules - See `~/.config/mosaic/guides/typescript.md` for mandatory TypeScript rules
<!-- Add project-specific patterns as you discover them --> <!-- Add project-specific patterns as you discover them -->
## Common Gotchas ## Common Gotchas

View File

@@ -9,13 +9,13 @@
| Task Type | Guide | | Task Type | Guide |
|-----------|-------| |-----------|-------|
| Bootstrapping this project | `~/.mosaic/guides/bootstrap.md` | | Bootstrapping this project | `~/.config/mosaic/guides/bootstrap.md` |
| Orchestrating autonomous tasks | `~/.mosaic/guides/orchestrator.md` | | Orchestrating autonomous tasks | `~/.config/mosaic/guides/orchestrator.md` |
| Ralph autonomous development | `~/.mosaic/guides/ralph-autonomous.md` | | Ralph autonomous development | `~/.config/mosaic/guides/ralph-autonomous.md` |
| Frontend development | `~/.mosaic/guides/frontend.md` | | Frontend development | `~/.config/mosaic/guides/frontend.md` |
| TypeScript strict typing | `~/.mosaic/guides/typescript.md` | | TypeScript strict typing | `~/.config/mosaic/guides/typescript.md` |
| Code review | `~/.mosaic/guides/code-review.md` | | Code review | `~/.config/mosaic/guides/code-review.md` |
| QA/Testing | `~/.mosaic/guides/qa-testing.md` | | QA/Testing | `~/.config/mosaic/guides/qa-testing.md` |
## Technology Stack ## Technology Stack
@@ -93,14 +93,14 @@ After completing code changes, run independent reviews:
```bash ```bash
# Code quality review (Codex) # Code quality review (Codex)
~/.mosaic/rails/codex/codex-code-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-code-review.sh --uncommitted
# Security review (Codex) # Security review (Codex)
~/.mosaic/rails/codex/codex-security-review.sh --uncommitted ~/.config/mosaic/rails/codex/codex-security-review.sh --uncommitted
``` ```
**Fallback:** If Codex is unavailable, use Claude's built-in review skills. **Fallback:** If Codex is unavailable, use Claude's built-in review skills.
See `~/.mosaic/guides/code-review.md` for the full review checklist. See `~/.config/mosaic/guides/code-review.md` for the full review checklist.
## Secrets Management ## Secrets Management