Skip to content

[plan] Add spinner integration for workflow compilation progress #7221

@github-actions

Description

@github-actions

Objective

Integrate huh/spinner to show progress feedback during workflow compilation in the interactive builder.

Context

After users complete the interactive form, the workflow compilation happens silently. This can be confusing, especially if compilation takes time. The huh library provides a built-in spinner component perfect for this use case.

Approach

Use huh/spinner to show compilation progress:

import "github.com/charmbracelet/huh/spinner"

func (b *InteractiveWorkflowBuilder) compileWorkflow(verbose bool) error {
    var compileErr error
    
    err := spinner.New().
        Title("Compiling your workflow...").
        Action(func() {
            config := CompileConfig{
                WorkflowFiles: []string{b.workflowPath},
                Verbose:       verbose,
            }
            _, compileErr = CompileWorkflows(config)
        }).
        Run()
    
    if err != nil {
        return err
    }
    return compileErr
}

Consider adding:

  • Success message after compilation completes
  • Error handling with clear messages
  • Optional accessible mode support

Files to Modify

  • Update: pkg/cli/interactive.go - Add spinner to compilation step
  • Update: go.mod - Ensure huh/spinner is imported (likely already available)

Acceptance Criteria

AI generated by Plan Command for discussion #7214

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions