ops(OPS55): worktree respeita WORKTREES_ROOT do .forgejo/worktree.env #26

Merged
fsolla merged 2 commits from OPS55-worktree-worktrees-root-env into main 2026-08-18 01:53:28 +00:00
2 changed files with 6 additions and 1 deletions

5
.forgejo/worktree.env Normal file
View file

@ -0,0 +1,5 @@
FORGEJO_REPOSITORY=fsolla/teqo
# Mantém o root atual enquanto houver sessões opencode ativas nos worktrees
# antigos (OPS52/OPS53/PUB5 em ~/.cursor/worktrees/teqo). Quando todas
# fecharem, migrar para ~/.worktrees/teqo (git worktree move) e trocar aqui.
WORKTREES_ROOT=~/.cursor/worktrees/teqo

View file

@ -141,7 +141,7 @@ import {
} from './lib/worktree.mjs'
const die = dieAgent('worktree')
const WORKTREES_ROOT = join(homedir(), '.cursor', 'worktrees', 'teqo')
const WORKTREES_ROOT = process.env.WORKTREES_ROOT ?? join(homedir(), '.cursor', 'worktrees', 'teqo')
/**
* True when the interactive terminal shell function (`.agents/shell/worktree.sh`)