From 199e5750e93b2636cabb63423fcb968a85a0a21a Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 13 Mar 2026 20:59:40 +0000 Subject: [PATCH] docs: document checkout: false support for disabling agent job checkout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add documentation for the `checkout: false` frontmatter option introduced in #20844, which allows users to suppress the default `actions/checkout` step injected into the agent job — useful for workflows that use the GitHub MCP server or other mechanisms that do not require a local clone. Co-Authored-By: Claude Sonnet 4.6 --- .../content/docs/reference/cross-repository.md | 16 ++++++++++++++-- .../content/docs/reference/frontmatter-full.md | 9 +++++++-- docs/src/content/docs/reference/frontmatter.md | 8 +++++++- 3 files changed, 28 insertions(+), 5 deletions(-) diff --git a/docs/src/content/docs/reference/cross-repository.md b/docs/src/content/docs/reference/cross-repository.md index 00907eefaaf..fa4f7f20b27 100644 --- a/docs/src/content/docs/reference/cross-repository.md +++ b/docs/src/content/docs/reference/cross-repository.md @@ -19,9 +19,21 @@ All require authentication beyond the default `GITHUB_TOKEN`, which is scoped to ## Cross-repository Checkout (`checkout:`) -The `checkout:` frontmatter field controls how `actions/checkout` is invoked in the agent job. Configure custom checkout settings or check out multiple repositories. +The `checkout:` frontmatter field controls how `actions/checkout` is invoked in the agent job. Configure custom checkout settings, check out multiple repositories, or disable checkout entirely. -If only a the current repository, you can use `checkout:` to override default checkout settings (e.g., fetch depth, sparse checkout) without needing to define a custom job: +### Disabling Checkout (`checkout: false`) + +Set `checkout: false` to suppress the default `actions/checkout` step entirely. Use this for workflows that access repositories through MCP servers or other mechanisms that do not require a local clone: + +```yaml wrap +checkout: false +``` + +This is equivalent to omitting the checkout step from the agent job. Custom dev-mode steps (such as "Checkout actions folder") are unaffected. + +### Custom Checkout Settings + +If only using the current repository, you can use `checkout:` to override default checkout settings (e.g., fetch depth, sparse checkout) without needing to define a custom job: ```yaml wrap checkout: diff --git a/docs/src/content/docs/reference/frontmatter-full.md b/docs/src/content/docs/reference/frontmatter-full.md index 9f3853e0a7e..03fa19f7123 100644 --- a/docs/src/content/docs/reference/frontmatter-full.md +++ b/docs/src/content/docs/reference/frontmatter-full.md @@ -4915,9 +4915,14 @@ runtimes: # (optional) # This field supports multiple formats (oneOf): -# Option 1: Single checkout configuration for the default workspace +# Option 1: Disable checkout entirely (no actions/checkout step is injected). +# Useful for workflows that access repositories via MCP servers or other +# mechanisms that do not require a local clone. +# checkout: false -# Option 2: Multiple checkout configurations +# Option 2: Single checkout configuration for the default workspace + +# Option 3: Multiple checkout configurations checkout: [] # Array items: undefined diff --git a/docs/src/content/docs/reference/frontmatter.md b/docs/src/content/docs/reference/frontmatter.md index 2800250c447..e51d938a77b 100644 --- a/docs/src/content/docs/reference/frontmatter.md +++ b/docs/src/content/docs/reference/frontmatter.md @@ -610,7 +610,13 @@ if: github.event_name == 'push' Configure how `actions/checkout` is invoked in the agent job. Override default checkout settings or check out multiple repositories for cross-repository workflows. -See [Cross-Repository Operations](/gh-aw/reference/cross-repository/) for complete documentation on checkout configuration options (including `fetch:`), merging behavior, and cross-repo examples. +Set `checkout: false` to disable the default repository checkout entirely — useful for workflows that access repositories through MCP servers or other mechanisms that do not require a local clone: + +```yaml wrap +checkout: false +``` + +See [Cross-Repository Operations](/gh-aw/reference/cross-repository/) for complete documentation on checkout configuration options (including `fetch:`, `checkout: false`), merging behavior, and cross-repo examples. ## Custom Steps (`steps:`)