[GRASS-dev] [bug #4629] (grass) v.db.droptable: it's interactive and doesn't work in tcltk GUI mode

mneteler wrote (Tue, Jun 20 2006 11:30:36):

The code contains:

# this may not work in GUI mode:
echo "Are you sure (y/n)? [n]"
read ans

which needs to be fixed (question is how,
add a -f force flag)?

(Markus has added the flag.)

Why the force-flag and the Y/N question at all? g.remove doesn't ask and
that's just OK, why shouldn't v.db.droptable follow?

Or is it only doable for Grass 7?

Maciek

-------------------------------------------- Managed by Request Tracker

On Wed, Jul 26, 2006 at 06:49:26PM +0200, Maciek Sieczka via RT wrote:

mneteler wrote (Tue, Jun 20 2006 11:30:36):

> The code contains:
>
> # this may not work in GUI mode:
> echo "Are you sure (y/n)? [n]"
> read ans
>
> which needs to be fixed (question is how,
> add a -f force flag)?

(Markus has added the flag.)

Why the force-flag and the Y/N question at all? g.remove doesn't ask and
that's just OK, why shouldn't v.db.droptable follow?

Nearly all commands *refuse* to overwrite (hence --o).
g.remove is an exception (maybe a bad one).

v.db.droptable follows the mainstream behaviour which I like
(better actively say that you want to delete something that
crying the rest of the week for a non-backup'ed (big) table).

My 0.02 cent,

Markus