diff --git a/cmd/gh-aw/argument_syntax_test.go b/cmd/gh-aw/argument_syntax_test.go index 38d732a835..46a53f957f 100644 --- a/cmd/gh-aw/argument_syntax_test.go +++ b/cmd/gh-aw/argument_syntax_test.go @@ -24,9 +24,9 @@ func TestArgumentSyntaxConsistency(t *testing.T) { }{ // Commands with required arguments (using angle brackets <>) { - name: "audit command requires run-id", + name: "audit command requires run-id-or-url", command: cli.NewAuditCommand(), - expectedUse: "audit ", + expectedUse: "audit ", argsValidator: "ExactArgs(1)", shouldValidate: func(cmd *cobra.Command) error { return cmd.Args(cmd, []string{"123456"}) }, }, diff --git a/pkg/cli/add_command.go b/pkg/cli/add_command.go index 1c7305c933..6b2020526e 100644 --- a/pkg/cli/add_command.go +++ b/pkg/cli/add_command.go @@ -74,7 +74,7 @@ Workflow specifications: The -n flag allows you to specify a custom name for the workflow file (only applies to the first workflow when adding multiple). The --dir flag allows you to specify a subdirectory under .github/workflows/ where the workflow will be added. -The --create-pull-request flag (or --pr) creates a pull request with the workflow changes. +The --create-pull-request flag creates a pull request with the workflow changes. The --force flag overwrites existing workflow files. Note: To create a new workflow from scratch, use the 'new' command instead. diff --git a/pkg/cli/audit.go b/pkg/cli/audit.go index bfe3d96d0b..6fca34096f 100644 --- a/pkg/cli/audit.go +++ b/pkg/cli/audit.go @@ -26,8 +26,8 @@ var auditLog = logger.New("cli:audit") // NewAuditCommand creates the audit command func NewAuditCommand() *cobra.Command { cmd := &cobra.Command{ - Use: "audit ", - Short: "Audit a workflow run and generate a detailed report", + Use: "audit ", + Short: "Audit a workflow run given a run ID or URL and generate a detailed report", Long: `Audit a single workflow run by downloading artifacts and logs, detecting errors, analyzing MCP tool usage, and generating a concise Markdown report suitable for AI agents. diff --git a/pkg/cli/mcp_inspect.go b/pkg/cli/mcp_inspect.go index 68b0021c55..27eef34910 100644 --- a/pkg/cli/mcp_inspect.go +++ b/pkg/cli/mcp_inspect.go @@ -201,7 +201,7 @@ The command will: - Start each MCP server (stdio, docker, http) - Automatically start and inspect mcp-scripts server if present - Query available tools, resources, and roots -- Validate required secrets are available +- Validate required secrets are available - Display results in formatted tables with error details`, Args: cobra.MaximumNArgs(1), RunE: func(cmd *cobra.Command, args []string) error { diff --git a/pkg/cli/trial_command.go b/pkg/cli/trial_command.go index f0c8fd3c0d..97141023d7 100644 --- a/pkg/cli/trial_command.go +++ b/pkg/cli/trial_command.go @@ -90,7 +90,7 @@ Workflows from different repositories: ` + string(constants.CLIExtensionPrefix) + ` trial githubnext/agentics/daily-plan myorg/myrepo/custom-workflow Repository mode examples: - ` + string(constants.CLIExtensionPrefix) + ` trial githubnext/agentics/my-workflow --repo myorg/myrepo # Run directly in myorg/myrepo (no simulation) + ` + string(constants.CLIExtensionPrefix) + ` trial githubnext/agentics/my-workflow --host-repo myorg/myrepo # Run directly in myorg/myrepo (no simulation) ` + string(constants.CLIExtensionPrefix) + ` trial githubnext/agentics/my-workflow --logical-repo myorg/myrepo # Simulate running against myorg/myrepo ` + string(constants.CLIExtensionPrefix) + ` trial githubnext/agentics/my-workflow --clone-repo myorg/myrepo # Clone myorg/myrepo contents into host @@ -110,7 +110,7 @@ Advanced examples: Repository modes: - Default mode (no flags): Creates a temporary trial repository and simulates execution as if running against the current repository (github.repository context points to current repo) - --logical-repo REPO: Simulates execution against a specified repository (github.repository context points to REPO while actually running in a temporary trial repository) -- --host-repo REPO (or --repo REPO): Uses the specified repository as the host for trial execution instead of creating a temporary one +- --host-repo REPO: Uses the specified repository as the host for trial execution instead of creating a temporary one - --clone-repo REPO: Clones the specified repository's contents into the trial repository before execution (useful for testing against actual repository state) All workflows must support workflow_dispatch trigger to be used in trial mode. @@ -182,6 +182,7 @@ Trial results are saved both locally (in trials/ directory) and in the host repo cmd.Flags().String("host-repo", "", "Custom host repository slug (defaults to '/gh-aw-trial'). Use '.' for current repository") cmd.Flags().String("repo", "", "Alias for --host-repo: the repository where workflows are installed and run (note: different semantics from --repo in other commands)") + _ = cmd.Flags().MarkHidden("repo") // Hide alias to avoid semantic confusion with --repo in other commands cmd.Flags().Bool("delete-host-repo-after", false, "Delete the host repository after completion (default: keep)") cmd.Flags().Bool("force-delete-host-repo-before", false, "Force delete the host repository before creation, if it exists before creating it") cmd.Flags().BoolP("yes", "y", false, "Skip confirmation prompts")