|
@@ -14,12 +14,15 @@ sub usage;
|
14
|
14
|
|
15
|
15
|
my $direction = 'encz.en';
|
16
|
16
|
my $lines = 25;
|
|
17
|
+my $max_lines = 50;
|
|
18
|
+my $long = 0;
|
17
|
19
|
my $man = 0;
|
18
|
20
|
my $help = 0;
|
19
|
21
|
my $host = 'www.slovnik.cz';
|
20
|
22
|
|
21
|
23
|
GetOptions(
|
22
|
|
- 'lines|l=i' => \$lines,
|
|
24
|
+ 'long|l' => \$long,
|
|
25
|
+ 'lines|n=i' => \$lines,
|
23
|
26
|
'direction|d=s' => \$direction,
|
24
|
27
|
'help|?|h' => \$help,
|
25
|
28
|
'man' => \$man
|
|
@@ -27,6 +30,8 @@ GetOptions(
|
27
|
30
|
pod2usage(1) if $help;
|
28
|
31
|
pod2usage(-exitstatus => 0, -verbose => 2) if $man;
|
29
|
32
|
|
|
33
|
+$lines = $max_lines if $long;
|
|
34
|
+
|
30
|
35
|
my $word = shift or usage;
|
31
|
36
|
|
32
|
37
|
my $query = sprintf(
|
|
@@ -115,7 +120,11 @@ one of following:
|
115
|
120
|
lacz.la, lacz.cz, eocz.eo, eocz.cz, eosk.eo, eosk.sk,
|
116
|
121
|
plcz.pl, plcz.cz
|
117
|
122
|
|
118
|
|
-=item B<-l> I<LINES>, B<--lines=>I<LINES>
|
|
123
|
+=item B<-l>, B<--long>
|
|
124
|
+
|
|
125
|
+Same as C<--lines=50>, which is maximum supported by API
|
|
126
|
+
|
|
127
|
+=item B<-n> I<LINES>, B<--lines=>I<LINES>
|
119
|
128
|
|
120
|
129
|
Number of lines fetched fronm the service and displayed to stdout.
|
121
|
130
|
Default is 25, but since www.slovnik.cz provides simplistic interface
|