fix(workflow): reuse source worktree for contextual launches#301
Merged
jcanizalez merged 2 commits intomainfrom May 8, 2026
Merged
fix(workflow): reuse source worktree for contextual launches#301jcanizalez merged 2 commits intomainfrom
jcanizalez merged 2 commits intomainfrom
Conversation
Contextual workflows launched from a worktree-backed card resolved useWorktree=true via 'fromContext' but never set existingWorktreePath, so createTerminal/createHeadlessSession spawned a fresh worktree off the project root and the agent ran in the wrong cwd. Add a fromContext branch that resolves the source/task worktreePath and passes it as existingWorktreePath; the existing inheritedWorktree flag keeps cleanup from deleting the reused worktree.
There was a problem hiding this comment.
Pull request overview
Fixes contextual workflow launches so that useWorktree: 'fromContext' correctly reuses the source/task’s existing worktree (via existingWorktreePath), preventing agents from starting in an unintended fresh worktree/cwd. Also updates repository references to reflect the GitHub org rename to vorn-run/vorn.
Changes:
- Reuse the contextual source/task
worktreePathwhen launching an agent withuseWorktree: 'fromContext'by passing it asexistingWorktreePath. - Update README/website/install scripts/electron-builder/MCP metadata to the new
vorn-run/vornrepository coordinates.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| website/index.html | Updates GitHub/release/install URLs and client-side repo constant to vorn-run/vorn. |
| src/renderer/lib/workflow-execution.ts | Adds fromContext worktree resolution to pass existingWorktreePath for contextual launches. |
| README.md | Updates badges and install/release links to vorn-run/vorn. |
| packages/mcp/package.json | Updates repository URL to vorn-run/vorn. |
| install.sh | Updates default repo slug to vorn-run/vorn. |
| install.ps1 | Updates default repo slug to vorn-run/vorn. |
| electron-builder.yml | Updates GitHub publish owner to vorn-run. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
useWorktree=truevia'fromContext'but never setexistingWorktreePath, socreateTerminal/createHeadlessSessionspawned a fresh worktree off the project root and the agent ran in the wrong cwd.fromContextbranch inexecuteNodethat resolves the source/taskworktreePathand passes it asexistingWorktreePath. The existinginheritedWorktreeflag keeps cleanup from deleting the reused worktree.jcanizalez/vorntovorn-run/vornacross README, install scripts, electron-builder config, MCP package metadata, and the website.Test plan
useWorktree: 'fromContext'; confirm the new agent lands in the same worktree path as the source.