Skip to content

fix(taskctl): pipeline commits land on dev branch instead of task feature branch #282

@randomm

Description

@randomm

Problem

When commitTask runs @ops to commit developer changes, the commit lands on dev branch instead of the task's feature branch (e.g. opencode/task-slug).

Observed: commits ea33c39b and bf508e61b both show [dev ...] in git log output from @ops session.

Root Cause

Worktree.create creates the worktree on branch opencode/<name> via git worktree add --no-checkout -b ${branch}. The worktree directory IS on the feature branch. However the @ops commit prompt now says to use task.worktree as workdir — but @ops may be running git add -A && git commit from the main project directory (which is on dev) instead of from the worktree.

OR the worktree's git reset --hard in Worktree.create is checking out dev HEAD, not creating a new branch from it.

Acceptance Criteria

  • Pipeline commits land on opencode/<task-slug> branch, not dev
  • After all job tasks are committed, @ops creates a PR from the consolidated branch to dev
  • bun test and bun run typecheck pass

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions