Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions cmd/gh-aw/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -721,7 +721,7 @@ Use "` + string(constants.CLIExtensionPrefix) + ` help all" to show help for all
compileCmd.Flags().String("gh-aw-ref", "", "Pin compiled workflows to a specific branch, tag, or commit SHA of github/gh-aw (e.g. main, my-feature, abc123). Branch and tag names are resolved to their full commit SHA at compile time so the baked-in ref is immutable. Equivalent to --action-mode release --action-tag <resolved-sha>. Cannot be combined with --action-tag or --action-mode. Use this to E2E-test workflows against a specific gh-aw revision")
compileCmd.Flags().Bool("validate", false, "Enable GitHub Actions workflow schema validation, container image validation, and action SHA validation")
compileCmd.Flags().BoolP("watch", "w", false, "Watch for changes to workflow files and recompile automatically")
compileCmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
compileCmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
compileCmd.Flags().String("workflows-dir", "", "Deprecated: use --dir instead")
_ = compileCmd.Flags().MarkDeprecated("workflows-dir", "use --dir instead")
compileCmd.Flags().Bool("no-emit", false, "Validate workflow without generating lock files")
Expand Down Expand Up @@ -772,7 +772,7 @@ Use "` + string(constants.CLIExtensionPrefix) + ` help all" to show help for all

// Add flags to remove command
removeCmd.Flags().Bool("keep-orphans", false, "Skip removal of orphaned include files that are no longer referenced by any workflow")
removeCmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
removeCmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
// Register completions for remove command
removeCmd.ValidArgsFunction = cli.CompleteWorkflowNames
cli.RegisterDirFlagCompletion(removeCmd, "dir")
Expand Down
4 changes: 2 additions & 2 deletions docs/src/content/docs/setup/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ gh aw add-wizard https://example.com/workflows/my-workflow.json # Arbitrary UR
gh aw add-wizard githubnext/agentics/ci-doctor --no-secret # Skip secret prompt
```

**Options:** `--no-secret`, `--dir/-d`, `--engine/-e`, `--no-gitattributes`, `--no-stop-after`, `--stop-after`
**Options:** `--no-secret`, `--dir/-d`, `--engine/-e`, `--no-gitattributes`, `--no-stop-after`, `--stop-after`, `--append`, `--no-security-scanner`

When the Copilot engine is selected, the wizard prompts the user to choose an authentication method: organization billing via [`permissions.copilot-requests: write`](/gh-aw/reference/auth/#copilot-requests-write-permission) (no PAT required), or a [`COPILOT_GITHUB_TOKEN`](/gh-aw/reference/auth/#copilot_github_token) personal access token. Selecting org billing injects the `copilot-requests: write` permission into the workflow frontmatter and skips the API key secret prompt.

Expand Down Expand Up @@ -720,7 +720,7 @@ gh aw upgrade --org my-org --create-issue --yes # Auto-accept per-repo confirma

**Options:** `--dir/-d`, `--no-fix`, `--no-actions`, `--no-compile`, `--disable-codemod`, `--create-pull-request`, `--create-issue`, `--org`, `--repos`, `--yes/-y`, `--audit`, `--json/-j`, `--approve`, `--pre-releases`

Org mode (`--org`) previews or creates upgrade pull requests across every repository in an organization. Use `--repos` to limit org mode to repositories matching one or more glob patterns, `--create-issue` to open an issue in each org repository with agentic workflows (requires `--org`), and `--yes/-y` to auto-accept org-mode create confirmations (required in CI).
Org mode (`--org`) previews or creates upgrade pull requests across every repository in an organization. Use `--repos` to limit org mode to repositories matching one or more glob patterns, `--create-issue` to open an issue in each org repository with agentic workflows (requires `--org`), and `--yes/-y` to auto-accept org-mode upgrade confirmations (required in CI).

Use `--disable-codemod` (repeatable) to skip specific codemod IDs during the embedded fix step. This flag is ignored when `--no-fix` is set.

Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/add_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ func registerAddCommandFlags(cmd *cobra.Command) {
cmd.Flags().Bool("no-gitattributes", false, "Skip updating .gitattributes file")

// Add workflow directory flag to add command
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")

// Add no-stop-after flag to add command
cmd.Flags().Bool("no-stop-after", false, "Remove any stop-after field from the workflow")
Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/add_wizard_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ Note: To create a new workflow from scratch, use the 'new' command instead.`,
cmd.Flags().Bool("no-gitattributes", false, "Skip updating .gitattributes file")

// Add workflow directory flag
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")

// Add no-stop-after flag
cmd.Flags().Bool("no-stop-after", false, "Remove any stop-after field from the workflow")
Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/deploy_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ func registerDeployFlags(cmd *cobra.Command) {
cmd.Flags().BoolP("force", "f", false, "Overwrite existing workflow files without confirmation")
cmd.Flags().String("append", "", "Append extra content to the end of agentic workflow on installation")
cmd.Flags().Bool("no-gitattributes", false, "Skip updating .gitattributes file")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
cmd.Flags().Bool("no-stop-after", false, "Remove any stop-after field from the workflow")
cmd.Flags().String("stop-after", "", "Override stop-after value in the workflow (e.g., '+48h', '2025-12-31 23:59:59')")
cmd.Flags().Bool("no-security-scanner", false, "Disable security scanning of workflow markdown content")
Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/fix_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ all steps and additionally:

cmd.Flags().Bool("write", false, "Write changes to files (without this flag, no changes are made)")
cmd.Flags().Bool("list-codemods", false, "List all available codemods and exit")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
cmd.Flags().StringSlice("disable-codemod", nil, "Disable specific codemod IDs during the fix step (repeatable)")

// Register completions
Expand Down
4 changes: 2 additions & 2 deletions pkg/cli/update_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ Note: In GitHub Enterprise repos, shorthand source specs resolve on your enterpr
cmd.Flags().Bool("major", false, "Allow major version updates when updating tagged releases")
cmd.Flags().BoolP("force", "f", false, "Force update even if no changes are detected")
addEngineFlag(cmd)
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
cmd.Flags().Bool("no-stop-after", false, "Remove any stop-after field from the workflow")
cmd.Flags().String("stop-after", "", "Override stop-after value in the workflow (e.g., '+48h', '2025-12-31 23:59:59')")
cmd.Flags().Bool("no-merge", false, "Override local changes with upstream version instead of merging")
Expand All @@ -181,7 +181,7 @@ Note: In GitHub Enterprise repos, shorthand source specs resolve on your enterpr
cmd.Flags().Bool("create-pull-request", false, "Create a pull request with the update changes")
cmd.Flags().Bool("pr", false, "Alias for --create-pull-request")
cmd.Flags().Bool("create-issue", false, "Open a GitHub issue in each org repository that has pending workflow updates (requires --org)")
cmd.Flags().BoolP("yes", "y", false, "Auto-accept org-mode create confirmations (required in CI)")
cmd.Flags().BoolP("yes", "y", false, "Auto-accept org-mode update confirmations (required in CI)")
cmd.Flags().String("cool-down", "7d", coolDownFlagUsage)
_ = cmd.Flags().MarkHidden("pr") // Hide the short alias from help output

Expand Down
4 changes: 2 additions & 2 deletions pkg/cli/upgrade_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ This command always upgrades all Markdown files in .github/workflows.`,
},
}

cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
cmd.Flags().Bool("no-fix", false, "Skip codemods, action version updates, and workflow compilation (only update agent files)")
cmd.Flags().Bool("no-actions", false, "Skip updating GitHub Actions versions (ignored when --no-fix is set)")
cmd.Flags().Bool("no-compile", false, "Skip recompiling workflows (do not modify lock files; ignored when --no-fix is set)")
Expand All @@ -158,7 +158,7 @@ This command always upgrades all Markdown files in .github/workflows.`,
cmd.Flags().Bool("pr", false, "Alias for --create-pull-request")
_ = cmd.Flags().MarkHidden("pr") // Hide the short alias from help output
cmd.Flags().Bool("create-issue", false, "Open a GitHub issue in each org repository with agentic workflows (requires --org)")
cmd.Flags().BoolP("yes", "y", false, "Auto-accept org-mode create confirmations (required in CI)")
cmd.Flags().BoolP("yes", "y", false, "Auto-accept org-mode upgrade confirmations (required in CI)")
cmd.Flags().Bool("audit", false, "Check dependency health without performing upgrades")
Comment on lines 160 to 162
cmd.Flags().Bool("pre-releases", false, "Include pre-release versions when checking for extension upgrades; pre-releases are installed by exact tag")
cmd.Flags().Bool("approve", false, "Approve all safe update changes. When strict mode is active (the default), the compiler emits warnings for new restricted secrets or unapproved action additions/removals not present in the existing gh-aw-manifest. Use this flag to approve and skip safe update enforcement")
Expand Down
2 changes: 1 addition & 1 deletion pkg/cli/validate_command.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ If no workflows are specified, all Markdown files in .github/workflows will be v
}

addEngineFlag(cmd)
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: .github/workflows)")
cmd.Flags().StringP("dir", "d", "", "Workflow directory (default: $GH_AW_WORKFLOWS_DIR or .github/workflows)")
cmd.Flags().Bool("strict", false, "Override frontmatter to enforce strict mode validation for all workflows (enforces action pinning, network config, safe-outputs, disallows write permissions and deprecated fields). Note: Workflows default to strict mode unless frontmatter sets strict: false")
cmd.Flags().BoolP("json", "j", false, "Output results in JSON format")
cmd.Flags().Bool("fail-fast", false, "Stop at the first validation error instead of collecting all errors")
Expand Down