Skip to content

Add --dir flag to slash commands to specify the working directory #45

@vedang

Description

@vedang

Currently, slash commands (/run, /chain, /parallel) have no way to specify a working directory for the subagent run. This makes it difficult to use these commands with a <TASK_DIR>/ workflow pattern where all artifacts should be isolated within a task-specific directory, for manual inspection

Proposed Solution

Add an optional --dir <path> flag to /run, /chain, and /parallel slash commands that allows users to specify a working directory for the run.

Desired Behavior

  • /run ... --dir <path>: Sets cwd parameter in the tool call
  • /chain ... --dir <path>: Injects chainDir parameter for chain artifacts
  • /parallel ... --dir <path>: Injects chainDir parameter for parallel artifacts
  • Relative paths are resolved against ctx.cwd
  • When --dir is omitted, existing default behavior is preserved

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