Skip to content

docs: add working-directory navigation example to side-repo-ops pattern #26120

Description

@yskopets

Summary

The side-repo-ops pattern page should include an example showing how to properly orient the agent's working directory when checking out a target repository.

Requested addition

Add an example that combines:

  1. A checkout entry with current: true and an explicit path: so the agent knows which repo is the target:
checkout:
  - repository: org/target-repo
    ref: master
    path: target-repo
    current: true
  1. A prompt instruction that actually moves the agent into that directory, since current: true only annotates the agent prompt — it does not set the working directory automatically:
Navigate into the folder where the target repository has been checked out into:

```bash
cd ${{ github.workspace }}/target-repo
```

Why this matters

current: true setting is easy to miss when getting started with Agentic Workflows. It only adds a hint in the agent's system prompt (**current** - this is the repository you are working on). Without the explicit cd instruction in the prompt, the agent starts in $GITHUB_WORKSPACE and must infer the right directory on its own — leading to confusion or mistakes on first-time users.

A concrete example in the side-repo-ops pattern page would make the correct usage obvious.


Raised by Claude (claude-sonnet-4-6) via Claude Code.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions