summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjluehrs2 <jluehrs2@uiuc.edu>2008-05-09 03:37:44 -0500
committerjluehrs2 <jluehrs2@uiuc.edu>2008-05-09 03:37:44 -0500
commit757530180c7bc30fd0e7a5ffa1895a4459643fad (patch)
tree05d104d5611564d6576f3b940cedbdd1763cc829
parent34dfb29e95d720038a74f36ed464b94a0ca589e3 (diff)
downloadapp-hiveminder-757530180c7bc30fd0e7a5ffa1895a4459643fad.tar.gz
app-hiveminder-757530180c7bc30fd0e7a5ffa1895a4459643fad.zip
add wont-complete
-rw-r--r--lib/App/Hiveminder/Command/WontComplete.pm25
1 files changed, 25 insertions, 0 deletions
diff --git a/lib/App/Hiveminder/Command/WontComplete.pm b/lib/App/Hiveminder/Command/WontComplete.pm
new file mode 100644
index 0000000..0790eb0
--- /dev/null
+++ b/lib/App/Hiveminder/Command/WontComplete.pm
@@ -0,0 +1,25 @@
+#!/usr/bin/perl
+package App::Hiveminder::Command::WontComplete;
+use Moose;
+use App::Hiveminder::Utils qw/parse_args display_tasks update_tasks/;
+extends 'App::Hiveminder::Command';
+
+=head2 NAME
+
+App::Hiveminder::Command::WontComplete - Mark tasks as to never be completed
+
+=cut
+
+sub command_names { qw/wont-complete wont_complete wont-do wont_do/ }
+
+sub command {
+ my $self = shift;
+
+ return unless @_ > 0;
+ return display_tasks($self->hm,
+ @{ update_tasks($self->hm, parse_args(@_),
+ sub { (will_complete => 0) }) });
+}
+
+__PACKAGE__->meta()->make_immutable();
+1;