Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 264150 - pybugz: control default confirm behavior
Summary: pybugz: control default confirm behavior
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High enhancement (vote)
Assignee: William Hubbs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-03-29 06:29 UTC by SpanKY
Modified: 2009-03-30 23:07 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description SpanKY gentoo-dev 2009-03-29 06:29:16 UTC
i like having the info summarized and shown before actually committing, but since the confirm prompt is [y/N], it means i have to hit 'y' before hitting enter.  a smoother workflow would be where i could change the default prompt to [Y/n].
Comment 1 William Hubbs gentoo-dev 2009-03-29 14:41:02 UTC
Post currently has a --no-confirm command line option which will skip
the confirmation question at the end of posting if it is on the command
line.

The other side of making the default answer to the confirmation question
Y is that it would be easy to confirm something you didn't mean to
confirm.

The other thing I could do though is to make bugz post behave more like
traditional unix commands such as cp or rm.  This would involve changing
the option to something like -i or --interactive and skipping the
confirmation question if the option is not on the command line.

What do you think about doing this?

Comment 2 SpanKY gentoo-dev 2009-03-29 16:05:11 UTC
i know about --no-confirm, but it doesnt do what i want ... there would be no confirmation step, just a straight submit

this is why i suggested a cmd line option so only people who wanted to flip y/N to Y/n would do so

flipping the behavior via -i makes sense to me.  pybugz would only prompt then on required information (product/component/etc...) and not do a confirm.  you could have -i then take an optional argument to determine the default behavior:
-i=y
-i=n
Comment 3 William Hubbs gentoo-dev 2009-03-30 15:21:20 UTC
I asked some people about this on IRC yesterday, and it seems that
having the prompt be [Y/n] instead of [y/N] is preferred.

I'll probably leave the --no-confirm option named the way it is since it
is just a straight submit.

What I'm thinking now is that I'll add an option which
would  switch the prompt to [y/N] if you want that.

I'm also open to a suggestion for the name of this option.  I
thought about --confirm-no, but we have a --no-confirm option, so would
that be confusing?

Comment 4 SpanKY gentoo-dev 2009-03-30 21:05:11 UTC
yes, having confirm-no and no-confirm would be confusing regardless of how you documented them in --help

how about --default-reply ?  it takes either y or n ...
Comment 5 William Hubbs gentoo-dev 2009-03-30 21:42:33 UTC
--default-reply seems ambiguous to me (default reply to what?), so how
about --default-confirm?
Comment 6 SpanKY gentoo-dev 2009-03-30 22:07:50 UTC
that's fine, doesnt matter much to me ;)
Comment 7 William Hubbs gentoo-dev 2009-03-30 23:07:13 UTC
This is fixed in git.  The option is --default-confirm.
Thanks for the report. :-)