summaryrefslogtreecommitdiff
path: root/scripts/dpkg-parsechangelog.pl
diff options
context:
space:
mode:
authorGuillem Jover <guillem@debian.org>2013-04-21 06:10:17 +0200
committerGuillem Jover <guillem@debian.org>2013-04-30 20:59:27 +0200
commit62bc788a45e4a641c28ca9c8c5b9bb08f29faed8 (patch)
tree440e84bf7a9a0ec56aea27cd7f5568ca581b2d46 /scripts/dpkg-parsechangelog.pl
parentd6851023a9ab87e3109fca3f2f9c6b5210575663 (diff)
downloaddpkg-62bc788a45e4a641c28ca9c8c5b9bb08f29faed8.tar.gz
Do not quote simple identifier hash keys in element accesses
Addresses ValuesAndExpressions::ProhibitInterpolationOfLiterals. Warned-by: perlcritic
Diffstat (limited to 'scripts/dpkg-parsechangelog.pl')
-rwxr-xr-xscripts/dpkg-parsechangelog.pl22
1 files changed, 12 insertions, 10 deletions
diff --git a/scripts/dpkg-parsechangelog.pl b/scripts/dpkg-parsechangelog.pl
index 8b980db2b..774265146 100755
--- a/scripts/dpkg-parsechangelog.pl
+++ b/scripts/dpkg-parsechangelog.pl
@@ -78,28 +78,30 @@ while (@ARGV) {
last unless $ARGV[0] =~ m/^-/;
$_ = shift(@ARGV);
if (m/^-L(.+)$/) {
- $options{"libdir"} = $1;
+ $options{libdir} = $1;
} elsif (m/^-F([0-9a-z]+)$/) {
- $options{"changelogformat"} = $1;
+ $options{changelogformat} = $1;
} elsif (m/^-l(.+)$/) {
- $options{"file"} = $1;
+ $options{file} = $1;
} elsif (m/^-(?:S|-show-field)(?:=(.+))?$/) {
$fieldname = $1 // shift(@ARGV);
} elsif (m/^--$/) {
last;
} elsif (m/^-([cfnostuv])(.*)$/) {
if (($1 eq "c") or ($1 eq "n")) {
- $options{"count"} = $2;
+ $options{count} = $2;
} elsif ($1 eq "f") {
- $options{"from"} = $2;
+ $options{from} = $2;
} elsif ($1 eq "o") {
- $options{"offset"} = $2;
+ $options{offset} = $2;
} elsif (($1 eq "s") or ($1 eq "v")) {
- $options{"since"} = $2;
+ $options{since} = $2;
} elsif ($1 eq "t") {
- $options{"to"} = $2;
+ $options{to} = $2;
} elsif ($1 eq "u") {
- $options{"until"} = $2;
+ ## no critic (ControlStructures::ProhibitUntilBlocks)
+ $options{until} = $2;
+ ## use critic
}
} elsif (m/^--(count|file|format|from|offset|since|to|until)(.*)$/) {
if ($2) {
@@ -108,7 +110,7 @@ while (@ARGV) {
$options{$1} = shift(@ARGV);
}
} elsif (m/^--all$/) {
- $options{"all"} = undef;
+ $options{all} = undef;
} elsif (m/^-(\?|-help)$/) {
usage(); exit(0);
} elsif (m/^--version$/) {