forked from vslavik/winsparkle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
WinSparkle.Targets
26 lines (21 loc) · 941 Bytes
/
WinSparkle.Targets
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
<?xml version="1.0" encoding="utf-8"?>
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003"
ToolsVersion="4.0">
<PropertyGroup>
<GettextBinDir>"$(SolutionDir)\packages\Gettext.Tools.0.20.2\tools\bin\"</GettextBinDir>
<Msgfmt>$(GettextBinDir)msgfmt.exe -c</Msgfmt>
</PropertyGroup>
<ItemGroup>
<TranslationFiles Include="translations\*.po" />
<CompiledTranslationFiles Include="translations\*.mo" />
</ItemGroup>
<Target Name="CopyTranslations_Poedit" BeforeTargets="ResourceCompile"
Inputs="@(TranslationFiles)"
Outputs="@(TranslationFiles->'%(Filename).mo')">
<Message Importance="High" Text="Compiling translations..." />
<Exec Command='$(Msgfmt) -o "translations\%(TranslationFiles.Filename).mo" @(TranslationFiles)' />
</Target>
<Target Name="CleanMOs" AfterTargets="Clean">
<Delete Files="@(CompiledTranslationFiles)" />
</Target>
</Project>