GothenburgBitFactory / taskwarrior

Taskwarrior - Command line Task Management
https://taskwarrior.org
MIT License
4.33k stars 291 forks source link

[TW-864] No more confirmation for undo? #899

Closed taskwarrior closed 6 years ago

taskwarrior commented 6 years ago

Michelle Crane on 2011-02-23T19:24:01Z says:

I've just moved up to 1.9.4 beta. Plus, I've recently turned verbose back on (implying I should be seeing extra confirmations, not less).

I noticed today that I did an undo operation, and there was no confirmation dialog. Usually, I get a "The undo command is not reversible. Are you sure you want to revert to the previous state? (y/n)", which I use very heavily.

Now, I do undo, and the last action just undoes - which I find disconcerting, because there is no redo function.

Use case: sometimes I notice that I've screwed something up - marked a task complete when it shouldn't have been. But I did it a few actions ago. So, I'll do undo, undo, undo, until I come the one that I want to fix. Then I just manually redo any other work that I did. A key part of this is being able to see what the undo operation would be. I'd hate to undo something and then realize that I really wanted to say "no".

What am I missing here? Is this new functionality? Can I turn the warning back on?

taskwarrior commented 6 years ago

Migrated metadata:

Created: 2011-02-23T19:24:01Z
Modified: 2014-02-09T02:10:13Z
taskwarrior commented 6 years ago

Federico Hernandez on 2011-02-23T19:39:37Z says:

I can't reproduce that in 1.9.4.beta1, Michelle: This with an empty, default .taskrc, that is verbose is on.

[fredde(at)supai ~]$ task 
[task list]
No matches.
[fredde(at)supai ~]$ task add foo
Created task 1.

[fredde(at)supai ~]$ task add bar
Created task 2.

[fredde(at)supai ~]$ task 
[task list]

ID Project Pri Due Active Age    Description
 2                        2 secs bar
 1                        9 secs foo

2 tasks
[fredde(at)supai ~]$ task 1 done 
Completed 1 'foo'.
Marked 1 task as done.

[fredde(at)supai ~]$ task undo 

The last modification was made 2/24/2011

             Prior Values                          Current Values                      
description  foo                                   foo
entry        2/24/2011                             2/24/2011
status       pending                               completed                           
uuid         315408bc-c913-49f6-8f41-29e9aaea79bb  315408bc-c913-49f6-8f41-29e9aaea79bb
end                                                2/24/2011                           

The undo command is not reversible.  Are you sure you want to revert to the previous state? (y/n) y
Modified task reverted.
[fredde(at)supai ~]$ task show verbose

Config variable Value
edit.verbose    yes
verbose         yes
taskwarrior commented 6 years ago

Michelle Crane on 2011-02-23T19:52:00Z says:

Thanks for the quick check Federico. I just did the exact same set of commands:

f:\dropbox\my dropbox\textfiles>task-1.9.4.beta1\src\task.exe add foo
Created task 75.

f:\dropbox\my dropbox\textfiles>task-1.9.4.beta1\src\task.exe add bar
Created task 76.

f:\dropbox\my dropbox\textfiles>task-1.9.4.beta1\src\task.exe new
ID Project             Pri Due        Countdown Active Age     Tags       Description
* - ------------------- --- ---------- --------- ------ ------- ---------- --------------------------------------------------------
75                                                      9 secs            bar
74                                                     15 secs            foo

f:\dropbox\my dropbox\textfiles>task-1.9.4.beta1\src\task.exe undo
The last modification was made 2/23/2011
             Prior Values  Current Values
* ----------  ------------  ------------------------------------
description                bar
entry                      2011-02-23.19:48
status                     pending
uuid                       7232aef6-70cf-b882-dd9d-d63e0868da74

Task removed.

f:\dropbox\my dropbox\textfiles>task-1.9.4.beta1\src\task.exe show verbose
Config variable Value
edit.verbose    yes
verbose         yes

But I'm not seeing the confirmation anywhere. If I go back to 1.9.3, I see the confirmation.

The version is showing (at)task 1.9.4.beta1 built for cygwin@.

taskwarrior commented 6 years ago

steve rader on 2011-02-24T11:15:09Z says:

I noticed today that I did an undo operation, and there was no confirmation dialog.

I think as of 1.9.4rc1 undo honors rc.confirmation as per http://taskwarrior.org/issues/show/634

Perhaps you have...

confirmation=off

and need to turn it on, or use...

task rc.confirmation=on undo

?

taskwarrior commented 6 years ago

Michelle Crane on 2011-02-24T11:22:33Z says:

Excellent Steve, you fixed my problem. I didn't think I had a confirmation issue, because it was working fine in 1.9.3. But I see from that bug that it wasn't working properly in 1.9.3., it's just that I was taking advantage of that flaw.

I just checked my .taskrc, and I have

confirmation=no

and I've had it that way for months at least. Looked good until I realized that the opposite of "on" is not "no". Yeesh. I turned it back "on", and now I'm good.

Thanks!

taskwarrior commented 6 years ago

Michelle Crane on 2011-02-24T11:30:20Z says:

Note: this bug can be closed. "stupid user". :)