Skip to content

Conversation

zen0bit
Copy link

@zen0bit zen0bit commented Feb 6, 2024

Hopefully Fixes #488

First trying go don't beat me

Desired changes

Usage: gum confirm [<prompt>]

Ask a user to confirm an action

Arguments:
  [<prompt>]    Prompt to display.

Flags:
  -h, --help                 Show context-sensitive help.
  -v, --version              Print the version number

      --default              Default confirmation action
      --affirmative="Yes"    The title of the affirmative action
      --negative="No"        The title of the negative action
      --timeout=0            Timeout until confirm returns selected value or default if provided ($GUM_CONFIRM_TIMEOUT)

Style Flags
  --prompt.foreground=""           Foreground Color ($GUM_CONFIRM_PROMPT_FOREGROUND)
  --selected.foreground="230"      Foreground Color ($GUM_CONFIRM_SELECTED_FOREGROUND)
  --unselected.foreground="254"    Foreground Color ($GUM_CONFIRM_UNSELECTED_FOREGROUND)
  --selected.background="1"        Selected Background Color ($GUM_CONFIRM_SELECTED_BACKGROUND)
  --unselected.background="2"      Unselected Background Color ($GUM_CONFIRM_UNSELECTED_BACKGROUND)

@maaslalani
Copy link
Contributor

Hey @zen0bit, thanks for the PR. I believe you would need to add these flags / options to confirm/options.go first and then use the values in confirm/command.go

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.

Change Usage: gum confirm
2 participants