[Po4a-commits] r2349 - /trunk/po4a
barbier-guest at users.alioth.debian.org
barbier-guest at users.alioth.debian.org
Mon Nov 22 23:16:36 UTC 2010
Author: barbier-guest
Date: Mon Nov 22 23:16:34 2010
New Revision: 2349
URL: http://svn.debian.org/wsvn/po4a/?sc=1&rev=2349
Log:
Expand variables when reading @-prefixed addenda files
Modified:
trunk/po4a
Modified: trunk/po4a
URL: http://svn.debian.org/wsvn/po4a/trunk/po4a?rev=2349&op=diff
==============================================================================
--- trunk/po4a (original)
+++ trunk/po4a Mon Nov 22 23:16:34 2010
@@ -969,6 +969,14 @@
chomp;
s/\s+$//;
next if length($_) == 0 or $_ =~ m/^\s*#/;
+ while (m/\$\((\w+)\)/) {
+ if (defined $po4a_opts{"variables"}{$1}) {
+ s/\$\((\Q$1\E)\)/$po4a_opts{"variables"}{$1}/g;
+ } else {
+ die wrap_ref_mod("$config_file:$nb", "",
+ gettext("Unknown variable: %s"), $1);
+ }
+ }
push(@new_list, "$lang:$_");
}
close LIST;
More information about the Po4a-commits
mailing list