Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Travel-Status-DE-HAFAS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
derf
Travel-Status-DE-HAFAS
Commits
8f6e84a4
Commit
8f6e84a4
authored
13 years ago
by
Birte Kristina Friesel
Browse files
Options
Downloads
Patches
Plain Diff
db-ris: Add -f/--full-route option
parent
ca37cdd0
No related branches found
Branches containing commit
Tags
4.13
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Changelog
+7
-1
7 additions, 1 deletion
Changelog
bin/db-ris
+24
-7
24 additions, 7 deletions
bin/db-ris
with
31 additions
and
8 deletions
Changelog
+
7
−
1
View file @
8f6e84a4
git HEAD
[db-ris]
* Add --full-route option
[Travel::Status::DE::DeutscheBahn]
* Fix bug when receiving no platform numbers from the DB RIS
* Result: Add route_timetable accessor containing station names and
[Travel::Status::DE::DeutscheBahn::Result]
* Add route_timetable accessor containing station names and
their corresponding arrival times
Travel::Status::DE::DeutscheBahn 0.05 - Tue Aug 09 2011
...
...
This diff is collapsed.
Click to expand it.
bin/db-ris
+
24
−
7
View file @
8f6e84a4
...
...
@@ -13,8 +13,9 @@ my %train_type;
my
(
$date
,
$time
);
my
$filter_via
;
my
$ignore_late
=
0
;
my
$types
=
q{}
;
my
$ignore_late
=
0
;
my
$show_full_route
=
0
;
my
$types
=
q{}
;
my
@output
;
...
...
@@ -22,6 +23,7 @@ binmode( STDOUT, ':encoding(utf-8)' );
GetOptions
(
'
d|date=s
'
=>
\
$date
,
'
f|full-route
'
=>
\
$show_full_route
,
'
h|help
'
=>
sub
{
show_help
(
0
)
},
'
L|ignore-late
'
=>
\
$ignore_late
,
'
m|mot=s
'
=>
\
$types
,
...
...
@@ -77,8 +79,14 @@ sub display_result {
}
for
my
$line
(
@lines
)
{
printf
(
join
(
q{ }
,
(
map
{
"
%-
${_}
s
"
}
@line_length
)
)
.
"
\n
",
@
{
$line
},
);
printf
(
join
(
q{ }
,
(
map
{
"
%-
${_}
s
"
}
@line_length
)
)
.
"
\n
",
@
{
$line
}[
0
..
5
]
);
if
(
$show_full_route
)
{
print
"
\n
"
.
$line
->
[
6
]
.
"
\n\n\n
";
}
}
return
;
...
...
@@ -106,9 +114,14 @@ for my $d ( $status->results() ) {
push
(
@output
,
[
$d
->
time
,
$d
->
train
,
join
(
q{ }
,
$d
->
route_interesting
),
$d
->
destination
,
$d
->
platform
,
$d
->
info
,
$d
->
time
,
$d
->
train
,
join
(
q{ }
,
$d
->
route_interesting
),
$d
->
destination
,
$d
->
platform
,
$d
->
info
,
join
(
"
\n
",
map
{
sprintf
(
'
%-5s %s
',
@
{
$_
}
)
}
$d
->
route_timetable
),
]
);
}
...
...
@@ -147,6 +160,10 @@ departure screens installed at most main stations.
Date to list departures for. Default: today.
=item B<-f>, B<--full-route>
Display complete routes (including arrival times) of all trains.
=item B<-L>, B<--ignore-late>
Do not display delayed trains.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment