Skip to content

Commit

Permalink
Add the --event option to log.
Browse files Browse the repository at this point in the history
  • Loading branch information
theory committed Jul 10, 2012
1 parent 1dc2e72 commit ab9d049
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/App/Sqitch/Command/log.pm
Expand Up @@ -61,6 +61,11 @@ EOF

$FORMATS{oneline} = '%h %l %c';

has event => (
is => 'ro',
isa => 'ArrayRef',
);

has change_pattern => (
is => 'ro',
isa => 'Str',
Expand Down Expand Up @@ -196,6 +201,7 @@ has formatter => (

sub options {
return qw(
event=s@
change-pattern|change|c=s
actor-pattern|actor|a=s
max-count|n=i
Expand Down Expand Up @@ -278,6 +284,7 @@ sub execute {

# Search the event log.
$iter = $engine->search_events(
event => $self->event,
change => $self->change_pattern,
actor => $self->actor_pattern,
limit => $self->max_count,
Expand Down
14 changes: 14 additions & 0 deletions lib/sqitch-log.pod
Expand Up @@ -18,6 +18,20 @@ expressions, and limit the results.

=over

=item C<--event>

Filter by event type. May be specified more than once. Allowed values are:

=over

=item * C<deploy>

=item * C<revert>

=item * C<fail>

=back

=item C<--change-pattern>

=item C<--change>
Expand Down

0 comments on commit ab9d049

Please sign in to comment.