diff options
author | Daniel Friesel <derf@finalrewind.org> | 2014-08-17 15:56:28 +0200 |
---|---|---|
committer | Daniel Friesel <derf@finalrewind.org> | 2014-08-17 15:56:28 +0200 |
commit | eae082a2110ec16d630b1a1d0f76fae3366e9632 (patch) | |
tree | fe7aef0a5e5abf601471162f51f0add10a18c5ec /bin/efa | |
parent | 430eda59e8739d195c79a7b42d5c1fd3a545d46c (diff) |
Add shortname to EFA service list
Diffstat (limited to 'bin/efa')
-rwxr-xr-x | bin/efa | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -223,11 +223,10 @@ if ( $opt->{exclude} ) { } if ( $opt->{discover} or $opt->{'auto-url'} ) { - for my $pair ( Travel::Routing::DE::EFA::get_efa_urls() ) { - my ( $url, $name ) = @{$pair}; + for my $service ( Travel::Routing::DE::EFA::get_efa_urls() ) { $efa = eval { Travel::Routing::DE::EFA->new( - efa_url => $url, + efa_url => $service->{url}, origin => [ @from, $from_type ], destination => [ @to, $to_type ], @@ -253,7 +252,11 @@ if ( $opt->{discover} or $opt->{'auto-url'} ) { if ( $opt->{'auto-url'} ) { last; } - printf( "%-55s (%s)\n", $url, $name ); + printf( + "%s / %s (%s)\n -> efa -s %s %s\n\n", + @{$service}{qw(name shortname url shortname)}, + join( ' ', map { "'$_'" } @ARGV ), + ); } } if ( $opt->{'discover'} ) { |