[rt-devel] Confusing user interface in commandline rt

Dan Shearer dan at tellurian.com.au
Mon Jun 3 20:18:15 EDT 2002


On Mon, 3 Jun 2002 stoffel at lucent.com wrote:

> 
> Rich> But --id *selects* by id, and --queue *CHANGES* the ticket's
> Rich> queue!  I propose that --queue should be synonymous with
> Rich> --limit-queue, and destructive options should be explicitly so,
> Rich> like "--set-queue".
> 
> Rich> The command which was messy was this:
> 
> Rich>   /opt/rt2/bin/rt --queue=Hostmaster --summary
> 
> Rich> which happily went through and changed all of my tickets into
> Rich> the Hostmaster queue until I noticed something was amiss and hit
> Rich> ^C. :(
> 
> I'd vote that we change this now, since I'm one of the few who use the
> command line tool all the time, this would be sure to screw me up.
> 
> I'd also like to propose that destructive commands like this prompt
> "Are you sure? [y|N] " by default.
> 
> This could be turned off by the flag -f to force the command without
> any prompting.

Since nearly everyone uses the commandline interface noninteractively,
what about inverting this logic. If there is a --prompt flag or
environment variable then destructive commands prompt, otherwise they just
go an be destructive. The reason I suggest this is because it is usually
harder to debug noninteractive commands, especially for beginners setting
things up for the first time with their particular MTA/webserver/etc.

On the other hand, anyone who habitually does things from the commandline
should be well enough informed to know that he should have an environment
variable set at all times for safety.

--
Dan Shearer
Open Source Manager
Mob: +61 411 49 1800
Tel: +61 8 8130 3104
dan at tellurian.com.au






More information about the Rt-devel mailing list