github cloudposse/atmos v1.202.0-rc.3

pre-release10 hours ago
feat: add interactive prompts for positional arguments @osterman (#1801) ## Summary

Implements interactive prompt support for CLI commands with positional arguments. When a required positional argument is missing and interactive mode is enabled (default), users see a filterable selector instead of an error message. This significantly improves discoverability and reduces cognitive load for users.

Key Features

  • Three prompt use cases: missing required flags, optional value flags (sentinel pattern), missing positional arguments
  • Graceful degradation: prompts only shown in TTY + non-CI environments, automatically disabled in pipelines
  • Height-limited selector: Limited to 20 visible rows to prevent excessive scrolling and rendering artifacts
  • Comprehensive testing: 399 lines of test coverage with multiple scenarios
  • Documentation: Updated docs and example implementations

Test Plan

  • Test atmos theme show without arguments → interactive selector appears
  • Test atmos theme show dracula with argument → executes normally
  • Test Ctrl-C abort → proper error handling
  • Test filtering with "/" → case-sensitive (documented Huh limitation)
  • Test non-interactive mode → graceful fallback to standard errors
  • Test in CI environment → prompts disabled automatically
  • All linter checks pass (new code only)

Summary by CodeRabbit

  • New Features

    • Interactive prompts for missing required flags, optional flag values (sentinel), and positional arguments in TTY terminals (enabled by default, disabled in CI)
    • New --interactive CLI flag and ATMOS_INTERACTIVE env var to toggle prompts
    • Theme show now supports interactive theme selection with completion when name is omitted
  • UI

    • Interactive prompt styling respects the current theme (button colors updated)
  • Documentation

    • User guide updates and a blog post explaining interactive prompts
  • Tests

    • Updated help snapshots and many new tests covering prompt-aware behavior

✏️ Tip: You can customize this high-level summary in your review settings.

Don't miss a new atmos release

NewReleases is sending notifications on new releases.