summaryrefslogtreecommitdiff
path: root/l10ntools/scripts/propex
diff options
context:
space:
mode:
Diffstat (limited to 'l10ntools/scripts/propex')
-rwxr-xr-xl10ntools/scripts/propex4
1 files changed, 3 insertions, 1 deletions
diff --git a/l10ntools/scripts/propex b/l10ntools/scripts/propex
index d7135cfc0aeb..6a402a213ae5 100755
--- a/l10ntools/scripts/propex
+++ b/l10ntools/scripts/propex
@@ -32,6 +32,7 @@ eval 'exec perl -S $0 ${1+"$@"}'
#
use strict;
+use File::Basename;
use Getopt::Std;
use Cwd;
@@ -40,7 +41,8 @@ getopts("ep:r:i:o:l:", \%options);
unless ( $options{i} =~ m/en_US/ ) {exit 0;}
-my $file = substr ( Cwd::abs_path($options{i}), length(Cwd::abs_path($options{r})) + 1 );
+my ($unsued1, $dir, $unused2) = File::Basename::fileparse($options{i});
+my $file = substr ( Cwd::abs_path($options{i}), length(Cwd::abs_path($dir . $options{r})) + 1 );
$file =~ s|/|\\|g;
open (INFILE, "<$options{i}") || die "propex: cannot open input file: $options{i}";