Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 22, 2026

Implementation Plan for gh aw list Command

  • Understand existing codebase structure
    • Review status command implementation
    • Review command registration in main.go
    • Understand test patterns
  • Create list command implementation
    • Create list_workflows_command.go with NewListCommand() function
    • Create RunListWorkflows() function with simplified logic
    • Support pattern filtering (like status)
    • Support JSON output (like status)
    • Display: Workflow name, Engine, Compiled status (minimal fields)
  • Add tests
    • Create list_workflows_command_test.go
    • Test JSON output
    • Test pattern filtering
  • Register command in main.go
    • Add to Development Commands group (parallel to status)
    • Register completions
  • Manual testing and validation
    • Test help text
    • Test basic list output
    • Test JSON output
    • Test pattern filtering
    • Verified all new tests pass
  • Merge main branch
    • Merged main and resolved conflicts
    • Recompiled workflows
  • Code review feedback
    • Use stringutil.NormalizeWorkflowName helper
    • Use extractWorkflowNameFromPath helper

Summary

Successfully implemented gh aw list command that:

  • Lists all workflows with basic information (Workflow, Engine, Compiled status)
  • Does NOT check GitHub workflow status or time remaining (unlike status)
  • Supports pattern filtering with case-insensitive substring matching
  • Supports JSON output for programmatic usage
  • Supports label filtering
  • Includes comprehensive tests that all pass
  • Properly registered in CLI with completions
  • Uses standard helper functions for workflow name extraction

Merged main branch and resolved conflicts in compiler_safe_outputs_config.go.

Original prompt

This section details on the original issue you should resolve

<issue_title>enhancement: add "gh aw list" as additional command</issue_title>
<issue_description>I would like to propose a new feature:
please add "gh aw list" as an additional command in parallel to "gh aw status"

there is already a "gh workflow list" command so having something similar in gh aw would make sense to me.
the semantic should be: just list the existing workflows, but do not check their status, Time Remaining etc.

</issue_description>

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


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

- Add new list command that shows basic workflow info without GitHub status
- Create list_workflows_command.go with NewListCommand and RunListWorkflows
- Add comprehensive tests in list_workflows_command_test.go
- Register command in main.go under Development Commands group
- Fix duplicate logger declaration in compiler_safe_outputs_config.go
- Command supports pattern filtering, JSON output, and label filtering

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Add gh aw list as additional command Add gh aw list command for fast workflow enumeration Jan 22, 2026
Copilot AI requested a review from pelikhan January 22, 2026 07:54
@pelikhan pelikhan marked this pull request as ready for review January 22, 2026 11:41
@pelikhan
Copy link
Contributor

@copilot Merge main and recompile

Copilot AI and others added 2 commits January 22, 2026 11:51
…ot/add-gh-aw-list-command

# Conflicts:
#	pkg/workflow/compiler_safe_outputs_config.go
Resolved merge conflict by accepting main's logger declaration and removing conflict markers

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copy link
Contributor Author

Copilot AI commented Jan 22, 2026

@copilot Merge main and recompile

Merged main branch and recompiled all workflows successfully (commit 7a319f0). Resolved merge conflict in compiler_safe_outputs_config.go by accepting main's logger declaration. All tests pass and command works correctly.


for _, file := range mdFiles {
base := filepath.Base(file)
name := strings.TrimSuffix(base, ".md")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot Use helpers to resolve names

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated to use stringutil.NormalizeWorkflowName() helper instead of manual TrimSuffix (commit a9d219f).

Replaced manual filepath.Base + TrimSuffix with NormalizeWorkflowName helper

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI requested a review from pelikhan January 22, 2026 12:08
var workflows []WorkflowListItem

for _, file := range mdFiles {
base := filepath.Base(file)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot look for other helper "extract..."

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated to use extractWorkflowNameFromPath() helper and removed unused filepath import (commit 78f8392).

Replaced manual filepath.Base + NormalizeWorkflowName with extractWorkflowNameFromPath helper and removed unused filepath import

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI requested a review from pelikhan January 22, 2026 12:15
@pelikhan pelikhan merged commit 7977aa0 into main Jan 22, 2026
83 checks passed
@pelikhan pelikhan deleted the copilot/add-gh-aw-list-command branch January 22, 2026 12:22
github-actions bot added a commit that referenced this pull request Jan 22, 2026
Add documentation for the new `gh aw list` command that was merged in
PR #11218. This command provides fast workflow enumeration without
querying GitHub API for workflow state.

Changes:
- Add gh aw list to "Most Common Commands" table
- Add complete documentation section under "Monitoring"
- Include usage examples and options
- Clarify differences from gh aw status command

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
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.

enhancement: add "gh aw list" as additional command

2 participants