App-SCM-Digest

 view release on metacpan or  search on metacpan

bin/scm-digest  view on Meta::CPAN

        $app->update();
    } elsif ($options{'get-email'}) {
        my $email = $app->get_email($options{'from'}, $options{'to'});
        if ($email) {
            print $email->as_string();
        }
    } else {
        print STDERR "Invalid options.\n";
        pod2usage(10);
    }
}

main();

1;

__END__

=head1 NAME

scm-digest - Send repository commit digest emails

=head1 SYNOPSIS

scm-digest [ options ]

Options:

  --conf {config}  Set configuration path (defaults to /etc/scm-digest.conf)
  --update         Initialise and update local repositories
  --get-email      Print digest email to standard output
  --from {time}    Only include commits made after this time in digest
  --to {time}      Only include commits made before this time in digest

Time format is '%Y-%m-%dT%H:%M:%S', e.g. '2000-12-25T22:00:00'.

The configuration file must be in YAML format.  Options that may be
specified are as follows:

  db_path:          /path/to/db
  repository_path:  /path/to/local/repositories
  timezone:         UTC
  ignore_errors:    0
  headers:
    From: From Address <from@example.org>
    To:   To Address <to@example.org>
    ...
  repositories:
    - name: test
      url: http://example.org/path/to/repository
      type: [git|hg]
    - name: local-test
      url: file:///path/to/repository
      type: [git|hg]
      ...

C<db_path>, C<repository_path>, and C<repositories> are mandatory
options.

C<timezone> is optional, and defaults to 'UTC'.  See
L<DateTime::TimeZone::Catalog> for a list of valid timezones.

C<ignore_errors> is an optional boolean, and defaults to false.  If
false, errors will cause the process to abort immediately.  If true,
errors will instead be printed to C<stderr>, and the process will
continue onto the next repository.

=cut



( run in 0.572 second using v1.01-cache-2.11-cpan-39bf76dae61 )