blob: 232b0a6d4ff1a8f6451cf6f3256fbe97bc440e0d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
#!/usr/bin/env perl
use strict;
use warnings;
use FixMyStreet::App;
use Open311::PopulateServiceList;
use Getopt::Long::Descriptive;
my ($opt, $usage) = describe_options(
'%c %o',
['verbose|v', "print out all services as they are found"],
['warn|w', "output warnings about any issues"],
['help', "print usage message and exit" ],
);
print($usage->text), exit if $opt->help;
my $council_list = FixMyStreet::App->model('DB::Open311conf')->search( {
send_method => 'Open311'
} );
my $verbose = 0;
$verbose = 1 if $opt->warn;
$verbose = 2 if $opt->verbose;
my $p = Open311::PopulateServiceList->new( council_list => $council_list, verbose => $verbose );
$p->process_councils;
|