gum icon indicating copy to clipboard operation
gum copied to clipboard

Change Usage: gum confirm

Open zen0bit opened this issue 1 year ago • 3 comments

I'm always frustrated if gum confirm button color don't respect my stylling

Describe the solution you'd like Add option to change button color from default pink to anything else --button.color = 5

Describe alternatives you've considered Don't use gum confirm

zen0bit avatar Jan 31 '24 17:01 zen0bit

@zen0bit I had this same problem. I was able to solve it this way:

gum confirm --selected.background 5

You can see the specific confirm option in confirm/options.go and the style reference in style/options.go.

jacobshu avatar Feb 05 '24 22:02 jacobshu

Change gum confirm usage message to something like this?

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)

zen0bit avatar Feb 06 '24 21:02 zen0bit

If anyone can point me where I can find it that USAGE: message for gum confirm, I could try my first commit in go... Maybe

zen0bit avatar Feb 06 '24 21:02 zen0bit