]> git.proxmox.com Git - proxmox-i18n.git/commitdiff
po2js generator: replace obsoleted Getopt::Std with Getopt::Long
authorThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 16 May 2023 15:22:41 +0000 (17:22 +0200)
committerThomas Lamprecht <t.lamprecht@proxmox.com>
Tue, 16 May 2023 16:09:00 +0000 (18:09 +0200)
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
po2js.pl

index f2f289e4df6c844ca125f63bdc9f2c7f3ea29c65..93c10c1ca8457c5ecd391013a730bfdfba261ea0 100755 (executable)
--- a/po2js.pl
+++ b/po2js.pl
@@ -2,19 +2,18 @@
 
 use strict;
 use warnings;
-use Getopt::Std;
-use Locale::PO;
-use JSON;
+
 use Encode;
+use Getopt::Long;
+use JSON;
+use Locale::PO;
 
 # current limits:
 # - we do not support plural. forms
 # - no message content support
 
 my $options = {};
-
-getopts('t:o:v:', $options) ||
-    die "unable to parse options\n";
+GetOptions($options, 't=s', 'o=s', 'v=s') or die "unable to parse options\n";
 
 die "no files specified\n" if !scalar(@ARGV);