Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 24, 2025

Thanks for assigning this issue to me. I'm starting to work on it and will keep this PR's description up to date as I form a plan and make progress.

Original prompt

This section details on the original issue you should resolve

<issue_title>[cli-consistency] Inconsistent flag naming: --workflows-dir vs --dir across commands</issue_title>
<issue_description>## Issue Description

Commands: Multiple commands (compile, add, update)
Type: Flag naming inconsistency
Priority: High

Current State

The codebase has inconsistent flag names for specifying the workflow directory:

compile command (cmd/gh-aw/main.go, lines 460-462):

compileCmd.Flags().String("dir", "", "Workflow directory (default: .github/workflows)")
compileCmd.Flags().String("workflows-dir", "", "Deprecated: use --dir instead")
_ = compileCmd.Flags().MarkDeprecated("workflows-dir", "use --dir instead")

add command (pkg/cli/add_command.go, line 64):

workflowDir, _ := cmd.Flags().GetString("dir")

update command (pkg/cli/update_command.go, line 70):

workflowDir, _ := cmd.Flags().GetString("dir")

Issue

While the deprecation is properly handled in the compile command, the help text and documentation could be confusing to users who see both --dir and the deprecated --workflows-dir mentioned.

Additionally, the --dir flag description says "Workflow directory" but this is less descriptive than it could be. Users might expect it to work with any directory, but it's specifically for the workflows directory.

Suggested Fix

  1. Keep the current deprecation - The deprecation handling is correct
  2. Improve the --dir flag description for clarity:
compileCmd.Flags().String("dir", "", "Workflows directory (default: .github/workflows)")
  1. Document the deprecation in the Long help text:
The --dir flag specifies the workflows directory (default: .github/workflows).
Note: --workflows-dir is deprecated, use --dir instead.

This makes the migration path clear while maintaining backward compatibility.

AI generated by CLI Consistency Checker

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[cli-consistency] Inconsistent flag naming: --workflows-dir vs --dir across commands

3 participants