You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Display variable descriptions in interactive mode prompts #116
Feature Request: Display Variable Descriptions in Interactive Mode
Current Behavior
When running struct generate in interactive mode, users are prompted for missing variables with only the variable name and default value:
❓ Enter value for my_variable [default_value]:
Desired Behavior
When a variable has a description field in the YAML configuration, it should be displayed in the interactive prompt to help users understand what the variable is for:
❓ Enter value for my_variable [default_value]:
Description: The name of your project
Example Configuration
variables:
- project_name:
type: stringdescription: "The name of your project"default: "MyProject"
- environment:
type: stringdescription: "Target deployment environment"enum: ["dev", "staging", "prod"]default: "dev"
Expected Output
❓ Enter value for project_name [MyProject]:
Description: The name of your project
❓ Enter value for environment [dev] (1) dev, (2) staging, (3) prod:
Description: Target deployment environment
Implementation Notes
The change should be in struct_module/template_renderer.py in the prompt_for_missing_vars method
Should support both description and help fields (for backward compatibility)
Should only display the description if it exists in the variable configuration
Should maintain current functionality for variables without descriptions
Should work for both regular variables and enum variables
Benefits
Improved user experience in interactive mode
Better understanding of what each variable represents
More self-documenting configurations
Reduces need to check YAML file while running interactive generation
Activity
feat: display variable descriptions in interactive mode prompts
feat: enhance interactive prompts with variable descriptions and cont…