Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -142,3 +142,8 @@ PORT=9900
# Must match the secret configured in GitHub repo Settings → Webhooks → Secret.
# If not set, all webhook payloads are rejected (fail-closed).
# GITHUB_WEBHOOK_SECRET=your-webhook-secret-here

# sutando workspace — set when src/ is a symlink into a packaged app bundle,
# so the bridges write tasks/results into the user workspace rather than
# the bundle's copy of src/. Leave unset for a normal git-clone install.
# SUTANDO_WORKSPACE=/path/to/workspace
11 changes: 10 additions & 1 deletion src/discord-bridge.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,16 @@

import discord

REPO = Path(__file__).resolve().parent.parent
# REPO resolution: prefer SUTANDO_WORKSPACE env var so the bridge writes to the
# user's workspace tasks/results/state dirs, not the app-bundle's copy. When
# this file lives under /Applications/Sutando.app/.../repo/src/, the workspace
# `src/` is typically a symlink into the bundle, so `Path(__file__).resolve()`
# walks INTO the bundle and `parent.parent` returns the bundle root rather
# than the workspace. That divergence stranded owner DMs on 2026-05-14 — the
# bridge wrote tasks to bundle-tasks/ while core agent watched workspace-tasks/.
import os
_workspace_env = os.environ.get("SUTANDO_WORKSPACE")
REPO = Path(_workspace_env) if _workspace_env else Path(__file__).resolve().parent.parent
sys.path.insert(0, str(Path(__file__).resolve().parent))
from util_paths import shared_personal_path # noqa: E402

Expand Down
Loading