$self->_find_changes($dir, $local, $remote);
},
local_commit_count => transform_exceptions {
- $self->_find_commits($dir, $local, $remote);
+ $self->_find_commit_count($dir, $local, $remote);
},
}
}
return { branches => \%branch };
}
-sub _find_commits {
+sub _find_commit_count {
my ($self, $dir, $local, $remote) = @_;
return { __error__ => "No remote" }
unless defined $remote;
local $ENV{GIT_DIR} = $dir;
my @lines = lines_from_command
['git', 'log', '--oneline', "$remote..$local"];
- return { count => scalar @lines };
+ return scalar @lines;
}
sub _find_changes {