##// END OF EJS Templates
templater: pass (context, mapping) down to unwraphybrid()...
templater: pass (context, mapping) down to unwraphybrid() See the subsequent patches for why. I initially thought it would be wrong to pass a mapping to flatten() and stringify() since these functions may be applied to a tree of generators, where each node should be bound to the mapping when it was evaluated. But, actually that isn't a problem. If an intermediate node has to override a mapping dict, it can do on unwraphybrid() and yield "unwrapped" generator of byte strings: "{f(g(v))}" # literal template example. ^^^^ # g() want to override a mapping, so it returns a wrapped # object 'G{V}' with partial mapping 'lm' attached. ^^^^^^^ # f() stringifies 'G{V}', starting from a mapping 'm'. # when unwrapping 'G{}', it updates 'm' with 'lm', and # passes it to 'V'. This structure is important for the formatter (and the hgweb) to build a static template keyword, which can't access a mapping dict until evaluation phase.

File last commit:

r32461:14e8fef9 stable
r37290:7d3bc1d4 default
Show More
locale.wxs
34 lines | 1.0 KiB | text/plain | TextLexer
<?xml version="1.0" encoding="utf-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<?include defines.wxi ?>
<?define hglocales =
da;de;el;fr;it;ja;pt_BR;ro;ru;sv;zh_CN;zh_TW
?>
<Fragment>
<ComponentGroup Id="localeFolder">
<?foreach LOC in $(var.hglocales) ?>
<ComponentRef Id="hg.locale.$(var.LOC)"/>
<?endforeach?>
</ComponentGroup>
</Fragment>
<Fragment>
<DirectoryRef Id="INSTALLDIR">
<Directory Id="localedir" Name="locale" FileSource="$(var.SourceDir)">
<?foreach LOC in $(var.hglocales) ?>
<Directory Id="hg.locale.$(var.LOC)" Name="$(var.LOC)">
<Directory Id="hg.locale.$(var.LOC).LC_MESSAGES" Name="LC_MESSAGES">
<Component Id="hg.locale.$(var.LOC)" Guid="*" Win64='$(var.IsX64)'>
<File Id="hg.mo.$(var.LOC)" Name="hg.mo" KeyPath="yes" />
</Component>
</Directory>
</Directory>
<?endforeach?>
</Directory>
</DirectoryRef>
</Fragment>
</Wix>