diff --git a/docs/src/content/docs/engines/claude.md b/docs/src/content/docs/engines/claude.md index 4bb94fe6f66..86220807349 100644 --- a/docs/src/content/docs/engines/claude.md +++ b/docs/src/content/docs/engines/claude.md @@ -36,6 +36,35 @@ Analyze the repository and create a concise daily status report covering: - Upcoming work items ``` +## Guided workflow authoring with Claude Code + +Claude Code users can initialize the repository and author agentic workflows with interactive guidance — no Copilot subscription required. + +### Initialize for Claude + +Run `gh aw init --engine claude` to configure the repository. The `--engine claude` flag skips Copilot-specific files (MCP server configuration, Copilot dispatcher skill) and only writes the files useful for any engine: `.gitattributes`, VS Code settings, and the custom agent file. + +```bash +gh aw init --engine claude +``` + +### Create a workflow + +Start Claude Code in your repository and run: + +```text wrap +Create a workflow for GitHub Agentic Workflows using https://raw.githubusercontent.com/github/gh-aw/main/create.md + +The purpose of the workflow is . +``` + +The agent fetches `create.md`, installs the `gh aw` CLI if needed, guides you through trigger selection, tools, safe outputs, and permissions, then generates `.github/workflows/.md` and compiles it to a `.lock.yml`. + +After the files are committed, set `engine: claude` in your workflow's frontmatter (if not already set) and add your `ANTHROPIC_API_KEY` as a repository secret. + +> [!NOTE] +> The `agentic-workflows create` Copilot Chat skill (enabled by `gh aw init` without `--engine`) requires a GitHub Copilot subscription. For Claude Code-only setups, `gh aw init --engine claude` plus the `create.md` prompt above is the equivalent guided flow. + ## When to choose gh-aw vs. anthropics/claude-code-action Choose gh-aw when the workflow should be defined in Markdown, run behind gh-aw sandboxing, switch engines without rewriting the workflow, or use safe outputs for validated GitHub writes. Choose [`anthropics/claude-code-action`](https://github.com/anthropics/claude-code-action) when the main goal is native Claude-driven PR assistance around comment and mention workflows. diff --git a/docs/src/content/docs/engines/codex.md b/docs/src/content/docs/engines/codex.md index 30e732df9d8..a15fe9080c0 100644 --- a/docs/src/content/docs/engines/codex.md +++ b/docs/src/content/docs/engines/codex.md @@ -9,6 +9,14 @@ OpenAI Codex is OpenAI's coding-focused agent runtime for repository work. gh-aw Set `engine: codex` and provide `OPENAI_API_KEY`. `CODEX_API_KEY` is also accepted and takes precedence when both are present. See [OpenAI authentication](/gh-aw/reference/auth/#openai_api_key) for the supported configuration. +### Initialize the repository + +Run `gh aw init --engine codex` to configure the repository. The `--engine codex` flag skips Copilot-specific files (MCP server configuration, Copilot dispatcher skill) and writes only the files useful for any engine: `.gitattributes`, VS Code settings, and the custom agent file. + +```bash +gh aw init --engine codex +``` + ```aw wrap title=".github/workflows/daily-status.md" --- on: diff --git a/docs/src/content/docs/engines/copilot.md b/docs/src/content/docs/engines/copilot.md index 08ec6ccc7c8..21624c6ada6 100644 --- a/docs/src/content/docs/engines/copilot.md +++ b/docs/src/content/docs/engines/copilot.md @@ -9,6 +9,14 @@ GitHub Copilot is the default gh-aw engine and runs GitHub Copilot agents inside Set `engine: copilot` or omit `engine:` because Copilot is the default. For organization-billed usage, grant `copilot-requests: write`; otherwise provide a `COPILOT_GITHUB_TOKEN` secret. See [Copilot authentication](/gh-aw/reference/auth/#copilot_github_token) for both paths. +### Initialize the repository + +Run `gh aw init` to configure the repository. Copilot is the default engine, so no `--engine` flag is required. This sets up the full Copilot integration: dispatcher skill, MCP server configuration, `.gitattributes`, VS Code settings, and the custom agent file. + +```bash +gh aw init +``` + ```aw wrap title=".github/workflows/daily-status.md" --- on: diff --git a/docs/src/content/docs/engines/gemini.md b/docs/src/content/docs/engines/gemini.md index b0e707aed9f..2ef4340b275 100644 --- a/docs/src/content/docs/engines/gemini.md +++ b/docs/src/content/docs/engines/gemini.md @@ -9,6 +9,14 @@ Google Gemini is Google's model family for coding and repository analysis. gh-aw Set `engine: gemini` and provide `GEMINI_API_KEY`, or configure keyless authentication with Google Workload Identity Federation. See [Gemini authentication](/gh-aw/reference/auth/#gemini_api_key) for the available setup paths. +### Initialize the repository + +Run `gh aw init --engine gemini` to configure the repository. The `--engine gemini` flag skips Copilot-specific files (MCP server configuration, Copilot dispatcher skill) and writes only the files useful for any engine: `.gitattributes`, VS Code settings, and the custom agent file. + +```bash +gh aw init --engine gemini +``` + ```aw wrap title=".github/workflows/daily-status.md" --- on: diff --git a/docs/src/content/docs/reference/faq.md b/docs/src/content/docs/reference/faq.md index fce964c5a5b..b792c4a2fa4 100644 --- a/docs/src/content/docs/reference/faq.md +++ b/docs/src/content/docs/reference/faq.md @@ -586,7 +586,18 @@ One workflow is simpler to maintain; multiple workflows give better separation o ### Should I create agentic workflows by hand editing or using AI? -Both work. AI-assisted authoring via `agentic-workflows create` in Copilot Chat gives interactive guidance and best practices; manual editing gives full control for advanced customization. See [Creating Workflows](/gh-aw/setup/creating-workflows/) or [Frontmatter Reference](/gh-aw/reference/frontmatter/). +Both work. AI-assisted authoring gives interactive guidance and best practices; manual editing gives full control for advanced customization. + +- **GitHub Copilot users**: after running `gh aw init`, use `agentic-workflows create` in Copilot Chat on github.com or the GitHub mobile app. +- **Claude Code and other CLI agent users**: run `gh aw init --engine claude` to initialize (skips Copilot-specific files), then use the `create.md` prompt directly — no Copilot subscription required: + + ```text wrap + Create a workflow for GitHub Agentic Workflows using https://raw.githubusercontent.com/github/gh-aw/main/create.md + + The purpose of the workflow is . + ``` + +See [Creating Workflows](/gh-aw/setup/creating-workflows/) or [Frontmatter Reference](/gh-aw/reference/frontmatter/). ### Can the agent use an existing branch specified at runtime (e.g., from a Jira issue)? diff --git a/docs/src/content/docs/setup/creating-workflows.mdx b/docs/src/content/docs/setup/creating-workflows.mdx index 6a9dec0f9ce..9633bb76a3e 100644 --- a/docs/src/content/docs/setup/creating-workflows.mdx +++ b/docs/src/content/docs/setup/creating-workflows.mdx @@ -132,6 +132,9 @@ Once initialized, you and your team can create and edit workflows by opening a C agentic-workflows Create a new workflow that... ``` +> [!NOTE] +> The `agentic-workflows` Copilot Chat skill requires a GitHub Copilot subscription. If you use Claude Code or another CLI coding agent without Copilot access, run `gh aw init --engine claude` instead — it skips the Copilot-specific MCP and skill files while still writing `.gitattributes`, VS Code settings, and the custom agent file. Then use the `create.md` approach in the [VSCode/Claude/Codex/Copilot](#vscodeclaudecodexcopilot) section above for guided workflow authoring. + ## Manual Editing If you prefer to create workflows manually, you can