projects
/
Biblio-Isis
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
changed options to -o offset and -l limit
[Biblio-Isis]
/
scripts
/
dump_isisdb.pl
diff --git
a/scripts/dump_isisdb.pl
b/scripts/dump_isisdb.pl
index
c2f5227
..
fe7c98c
100755
(executable)
--- a/
scripts/dump_isisdb.pl
+++ b/
scripts/dump_isisdb.pl
@@
-17,9
+17,9
@@
BEGIN {
}
my %opt;
}
my %opt;
-getopts('d
n
:', \%opt);
+getopts('d
o:l
:', \%opt);
-my $isisdb = shift @ARGV || die "usage: $0 [-
n number
] [-d] /path/to/isis/BIBL\n";
+my $isisdb = shift @ARGV || die "usage: $0 [-
o offset] [-l limit
] [-d] /path/to/isis/BIBL\n";
my $isis = Biblio::Isis->new (
isisdb => $isisdb,
my $isis = Biblio::Isis->new (
isisdb => $isisdb,
@@
-30,9
+30,9
@@
my $isis = Biblio::Isis->new (
print "rows: ",$isis->count,"\n\n";
print "rows: ",$isis->count,"\n\n";
-my $min = 1;
+my $min =
$opt{o} ||
1;
my $max = $isis->count;
my $max = $isis->count;
-$max =
$opt{n} if ($opt{n
});
+$max =
( $min + $opt{l} - 1 ) if ($opt{l
});
for my $mfn ($min .. $max) {
print STDERR Dumper($isis->to_hash($mfn)),"\n" if ($opt{'d'});
for my $mfn ($min .. $max) {
print STDERR Dumper($isis->to_hash($mfn)),"\n" if ($opt{'d'});