diff options
-rw-r--r-- | COPYING | 2 | ||||
-rw-r--r-- | README | 5 | ||||
-rwxr-xr-x | bin/ura-m | 27 | ||||
-rw-r--r-- | lib/Travel/Status/DE/ASEAG.pm | 6 | ||||
-rw-r--r-- | lib/Travel/Status/DE/MM.pm | 4 | ||||
-rw-r--r-- | lib/Travel/Status/DE/URA.pm | 4 | ||||
-rw-r--r-- | lib/Travel/Status/DE/URA/Result.pm | 2 | ||||
-rw-r--r-- | lib/Travel/Status/DE/URA/Stop.pm | 2 | ||||
-rw-r--r-- | lib/Travel/Status/GB/TFL.pm | 6 |
9 files changed, 26 insertions, 32 deletions
@@ -1,4 +1,4 @@ -Copyright (C) 2013 Daniel Friesel <derf@finalrewind.org> +Copyright (C) 2013 Birte Kristina Friesel <derf@finalrewind.org> All files in this distribution are licensed under the same terms as Perl itself. @@ -1,7 +1,10 @@ Travel::Status::DE::URA - interface to URA-based departure monitors ----------------------------------------------- -* <http://finalrewind.org/projects/Travel-Status-DE-URA/> +This project is **deprecated**, as it looks like there are no URA instances in the wild anymore. +It may not receive updates or security fixes. + +<https://finalrewind.org/projects/Travel-Status-DE-URA/> Dependencies @@ -3,8 +3,6 @@ use strict; use warnings; use 5.010; -no if $] >= 5.018, warnings => 'experimental::smartmatch'; - our $VERSION = '2.01'; binmode( STDOUT, ':encoding(utf-8)' ); @@ -12,7 +10,7 @@ binmode( STDOUT, ':encoding(utf-8)' ); use DateTime; use DateTime::Format::Duration; use Getopt::Long qw(:config no_ignore_case bundling); -use List::Util qw(first max); +use List::Util qw(any first max); use Travel::Status::DE::URA; my (@grep_lines); @@ -62,20 +60,21 @@ if ( not $service and $script_name ne 'ura-m' ) { @grep_lines = split( qr{,}, join( q{,}, @grep_lines ) ); for my $efield (@edata_pre) { - given ($efield) { - when ('a') { $edata{route_after} = 1; $calculate_routes = 1 } - when ('b') { $edata{route_before} = 1; $calculate_routes = 1 } - when ('f') { $edata{route_full} = 1; $calculate_routes = 1 } - when ('i') { $edata{indicator} = 1 } - when ('r') { $edata{route_interesting} = 1; $calculate_routes = 1 } - when ('T') { $edata{relative_times} = 1 } - default { $edata{$efield} = 1 } + if ( $efield eq 'a' ) { $edata{route_after} = 1; $calculate_routes = 1 } + elsif ( $efield eq 'b' ) { $edata{route_before} = 1; $calculate_routes = 1 } + elsif ( $efield eq 'f' ) { $edata{route_full} = 1; $calculate_routes = 1 } + elsif ( $efield eq 'i' ) { $edata{indicator} = 1 } + elsif ( $efield eq 'r' ) { + $edata{route_interesting} = 1; + $calculate_routes = 1; } + elsif ( $efield eq 'T' ) { $edata{relative_times} = 1 } + else { $edata{$efield} = 1 } } if ($service) { my $service_ref = first { lc( $_->{shortname} ) eq lc($service) } - Travel::Status::DE::URA::get_services(); + Travel::Status::DE::URA::get_services(); if ( not $service_ref ) { printf STDERR ( "Error: Unknown service '%s'. The following services are supported:\n\n", @@ -226,7 +225,7 @@ sub show_results { ) { - if ( ( @grep_lines and not( $d->line ~~ \@grep_lines ) ) ) { + if ( ( @grep_lines and not( any { $d->line eq $_ } @grep_lines ) ) ) { next; } my ( @line, @route ); @@ -461,7 +460,7 @@ Unknown. =head1 AUTHOR -Copyright (C) 2013-2016 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt> +Copyright (C) 2013-2023 by Birte Kristina Friesel E<lt>derf@finalrewind.orgE<gt> =head1 LICENSE diff --git a/lib/Travel/Status/DE/ASEAG.pm b/lib/Travel/Status/DE/ASEAG.pm index e568cf7..cc851e9 100644 --- a/lib/Travel/Status/DE/ASEAG.pm +++ b/lib/Travel/Status/DE/ASEAG.pm @@ -4,8 +4,6 @@ use strict; use warnings; use 5.010; -no if $] >= 5.018, warnings => 'experimental::smartmatch'; - our $VERSION = '2.01'; use parent 'Travel::Status::DE::URA'; @@ -85,11 +83,11 @@ Many. =head1 SEE ALSO -aseag-m(1), Travel::Status::DE::URA(3pm). +ura-m(1), Travel::Status::DE::URA(3pm). =head1 AUTHOR -Copyright (C) 2013-2016 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt> +Copyright (C) 2013-2016 by Birte Kristina Friesel E<lt>derf@finalrewind.orgE<gt> =head1 LICENSE diff --git a/lib/Travel/Status/DE/MM.pm b/lib/Travel/Status/DE/MM.pm index 373d6ae..0fa53ab 100644 --- a/lib/Travel/Status/DE/MM.pm +++ b/lib/Travel/Status/DE/MM.pm @@ -4,8 +4,6 @@ use strict; use warnings; use 5.010; -no if $] >= 5.018, warnings => 'experimental::smartmatch'; - our $VERSION = '2.01'; use parent 'Travel::Status::DE::URA'; @@ -85,7 +83,7 @@ Many. =head1 SEE ALSO -MM-m(1), Travel::Status::DE::URA(3pm). +ura-m(1), Travel::Status::DE::URA(3pm). =head1 AUTHOR diff --git a/lib/Travel/Status/DE/URA.pm b/lib/Travel/Status/DE/URA.pm index 35b77bd..8859583 100644 --- a/lib/Travel/Status/DE/URA.pm +++ b/lib/Travel/Status/DE/URA.pm @@ -5,8 +5,6 @@ use warnings; use 5.010; use utf8; -no if $] >= 5.018, warnings => 'experimental::smartmatch'; - our $VERSION = '2.01'; # create CONSTANTS for different Return Types @@ -602,7 +600,7 @@ Travel::Status::DE::URA::Result(3pm). =head1 AUTHOR -Copyright (C) 2013-2016 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt> +Copyright (C) 2013-2016 by Birte Kristina Friesel E<lt>derf@finalrewind.orgE<gt> =head1 LICENSE diff --git a/lib/Travel/Status/DE/URA/Result.pm b/lib/Travel/Status/DE/URA/Result.pm index b68e297..93e129e 100644 --- a/lib/Travel/Status/DE/URA/Result.pm +++ b/lib/Travel/Status/DE/URA/Result.pm @@ -283,7 +283,7 @@ Travel::Status::DE::URA(3pm), Travel::Status::DE::URA::Stop(3pm). =head1 AUTHOR -Copyright (C) 2013-2016 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt> +Copyright (C) 2013-2016 by Birte Kristina Friesel E<lt>derf@finalrewind.orgE<gt> =head1 LICENSE diff --git a/lib/Travel/Status/DE/URA/Stop.pm b/lib/Travel/Status/DE/URA/Stop.pm index 5b1a299..cd0c38f 100644 --- a/lib/Travel/Status/DE/URA/Stop.pm +++ b/lib/Travel/Status/DE/URA/Stop.pm @@ -107,7 +107,7 @@ Travel::Status::DE::URA(3pm). =head1 AUTHOR -Copyright (C) 2015-2016 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt> +Copyright (C) 2015-2016 by Birte Kristina Friesel E<lt>derf@finalrewind.orgE<gt> =head1 LICENSE diff --git a/lib/Travel/Status/GB/TFL.pm b/lib/Travel/Status/GB/TFL.pm index 209f77a..a6167cb 100644 --- a/lib/Travel/Status/GB/TFL.pm +++ b/lib/Travel/Status/GB/TFL.pm @@ -4,8 +4,6 @@ use strict; use warnings; use 5.010; -no if $] >= 5.018, warnings => 'experimental::smartmatch'; - our $VERSION = '2.01'; use parent 'Travel::Status::DE::URA'; @@ -85,11 +83,11 @@ Many. =head1 SEE ALSO -tfl-m(1), Travel::Status::DE::URA(3pm). +ura-m(1), Travel::Status::DE::URA(3pm). =head1 AUTHOR -Copyright (C) 2016 by Daniel Friesel E<lt>derf@finalrewind.orgE<gt> +Copyright (C) 2016 by Birte Kristina Friesel E<lt>derf@finalrewind.orgE<gt> =head1 LICENSE |