Turn delete action into multi action
This commit is contained in:
parent
9ada92a225
commit
a1f836972d
1 changed files with 8 additions and 8 deletions
|
@ -303,6 +303,14 @@
|
|||
(boundp 'taskwarrior-marks)
|
||||
(> (length taskwarrior-marks) 0)))
|
||||
|
||||
(defun taskwarrior-delete ()
|
||||
(interactive)
|
||||
(taskwarrior-multi-action 'taskwarrior--delete "Delete?"))
|
||||
|
||||
(defun taskwarrior--delete (id)
|
||||
"Delete task with id."
|
||||
(taskwarrior--mutable-shell-command "delete" id "" "" "yes"))
|
||||
|
||||
(defun taskwarrior-done ()
|
||||
(interactive)
|
||||
(taskwarrior-multi-action 'taskwarrior--done "Done?"))
|
||||
|
@ -319,14 +327,6 @@
|
|||
"Mark task as done."
|
||||
(taskwarrior--mutable-shell-command "done" id))
|
||||
|
||||
(defun taskwarrior-delete ()
|
||||
"Delete current task."
|
||||
(interactive)
|
||||
(let ((id (taskwarrior-id-at-point))
|
||||
(confirmation (yes-or-no-p "Delete?")))
|
||||
(when confirmation
|
||||
(taskwarrior--mutable-shell-command "delete" id "" "" "yes"))))
|
||||
|
||||
(defun taskwarrior-annotate (annotation)
|
||||
"Delete current task."
|
||||
(interactive "sAnnotation: ")
|
||||
|
|
Loading…
Reference in a new issue