Skip to content
This repository
Browse code

Add the `--event` option to `log`.

  • Loading branch information...
commit ab9d0491bd43ae8e4e62c4e435688b23d5d7defb 1 parent 1dc2e72
David E. Wheeler authored July 10, 2012
7  lib/App/Sqitch/Command/log.pm
@@ -61,6 +61,11 @@ EOF
61 61
 
62 62
 $FORMATS{oneline} = '%h %l %c';
63 63
 
  64
+has event => (
  65
+    is      => 'ro',
  66
+    isa     => 'ArrayRef',
  67
+);
  68
+
64 69
 has change_pattern => (
65 70
     is      => 'ro',
66 71
     isa     => 'Str',
@@ -196,6 +201,7 @@ has formatter => (
196 201
 
197 202
 sub options {
198 203
     return qw(
  204
+        event=s@
199 205
         change-pattern|change|c=s
200 206
         actor-pattern|actor|a=s
201 207
         max-count|n=i
@@ -278,6 +284,7 @@ sub execute {
278 284
 
279 285
     # Search the event log.
280 286
     $iter = $engine->search_events(
  287
+        event     => $self->event,
281 288
         change    => $self->change_pattern,
282 289
         actor     => $self->actor_pattern,
283 290
         limit     => $self->max_count,
14  lib/sqitch-log.pod
Source Rendered
@@ -18,6 +18,20 @@ expressions, and limit the results.
18 18
 
19 19
 =over
20 20
 
  21
+=item C<--event>
  22
+
  23
+Filter by event type. May be specified more than once. Allowed values are:
  24
+
  25
+=over
  26
+
  27
+=item * C<deploy>
  28
+
  29
+=item * C<revert>
  30
+
  31
+=item * C<fail>
  32
+
  33
+=back
  34
+
21 35
 =item C<--change-pattern>
22 36
 
23 37
 =item C<--change>

0 notes on commit ab9d049

Please sign in to comment.
Something went wrong with that request. Please try again.