Skip to content
This repository was archived by the owner on Sep 19, 2023. It is now read-only.

Commit f6059f9

Browse files
authored
Merge pull request #8 from panosk/nmtwizard
nmt-wizard-docker compatibility
2 parents 0f564c8 + f2df697 commit f6059f9

15 files changed

+435
-165
lines changed

SDL Trados Plugin/OpenNMT.csproj

+35-21
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
2-
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
2+
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
33
<PropertyGroup>
44
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
55
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
@@ -10,7 +10,7 @@
1010
<AppDesignerFolder>Properties</AppDesignerFolder>
1111
<RootNamespace>OpenNMT</RootNamespace>
1212
<AssemblyName>OpenNMT</AssemblyName>
13-
<TargetFrameworkVersion>v4.0</TargetFrameworkVersion>
13+
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
1414
<FileUpgradeFlags>
1515
</FileUpgradeFlags>
1616
<OldToolsVersion>3.5</OldToolsVersion>
@@ -39,50 +39,56 @@
3939
<AssemblyOriginatorKeyFile>key.snk</AssemblyOriginatorKeyFile>
4040
<RunPostBuildEvent>OnBuildSuccess</RunPostBuildEvent>
4141
<TargetFrameworkProfile />
42+
<NuGetPackageImportStamp>
43+
</NuGetPackageImportStamp>
4244
</PropertyGroup>
4345
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
4446
<DebugSymbols>true</DebugSymbols>
4547
<DebugType>full</DebugType>
4648
<Optimize>false</Optimize>
47-
<OutputPath>..\..\..\OpenNMTPluginBuild\</OutputPath>
49+
<OutputPath>..\..\..\..\AppData\Roaming\SDL\SDL Trados Studio\14\Plugins\Packages\</OutputPath>
4850
<DefineConstants>DEBUG;TRACE</DefineConstants>
4951
<ErrorReport>prompt</ErrorReport>
5052
<WarningLevel>4</WarningLevel>
5153
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
5254
<RegisterForComInterop>false</RegisterForComInterop>
55+
<Prefer32Bit>false</Prefer32Bit>
5356
</PropertyGroup>
5457
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
5558
<DebugType>full</DebugType>
5659
<Optimize>false</Optimize>
57-
<OutputPath>..\..\..\OpenNMTPluginBuild\</OutputPath>
60+
<OutputPath>..\..\..\..\AppData\Roaming\SDL\SDL Trados Studio\14\Plugins\Packages\</OutputPath>
5861
<DefineConstants>TRACE</DefineConstants>
5962
<ErrorReport>prompt</ErrorReport>
6063
<WarningLevel>4</WarningLevel>
6164
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
65+
<Prefer32Bit>false</Prefer32Bit>
6266
</PropertyGroup>
6367
<ItemGroup>
64-
<Reference Include="Newtonsoft.Json, Version=10.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
65-
<HintPath>packages\Newtonsoft.Json.10.0.3\lib\net35\Newtonsoft.Json.dll</HintPath>
66-
</Reference>
67-
<Reference Include="Sdl.Core.PluginFramework, Version=1.8.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
68-
<SpecificVersion>False</SpecificVersion>
69-
<HintPath>$(ProgramFiles)\SDL\SDL Trados Studio\Studio3\Sdl.Core.PluginFramework.dll</HintPath>
68+
<Reference Include="Newtonsoft.Json, Version=12.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
69+
<HintPath>packages\Newtonsoft.Json.12.0.2\lib\net40\Newtonsoft.Json.dll</HintPath>
7070
</Reference>
7171
<Reference Include="Sdl.Core.Globalization, Version=1.8.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
7272
<SpecificVersion>False</SpecificVersion>
73-
<HintPath>$(ProgramFiles)\SDL\SDL Trados Studio\Studio3\Sdl.Core.Globalization.dll</HintPath>
73+
<HintPath>..\..\..\..\..\..\Program Files (x86)\SDL\SDL Trados Studio\Studio5\Sdl.Core.Globalization.dll</HintPath>
74+
</Reference>
75+
<Reference Include="Sdl.Core.PluginFramework, Version=1.8.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
76+
<HintPath>packages\Sdl.Core.PluginFramework.1.8.0\lib\net45\Sdl.Core.PluginFramework.dll</HintPath>
77+
</Reference>
78+
<Reference Include="Sdl.Core.PluginFramework.PackageSupport, Version=1.8.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
79+
<HintPath>packages\Sdl.Core.PluginFramework.1.8.0\lib\net45\Sdl.Core.PluginFramework.PackageSupport.dll</HintPath>
7480
</Reference>
7581
<Reference Include="Sdl.LanguagePlatform.Core, Version=1.6.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
7682
<SpecificVersion>False</SpecificVersion>
77-
<HintPath>$(ProgramFiles)\SDL\SDL Trados Studio\Studio3\Sdl.LanguagePlatform.Core.dll</HintPath>
83+
<HintPath>..\..\..\..\..\..\Program Files (x86)\SDL\SDL Trados Studio\Studio5\Sdl.LanguagePlatform.Core.dll</HintPath>
7884
</Reference>
7985
<Reference Include="Sdl.LanguagePlatform.TranslationMemory, Version=1.6.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
8086
<SpecificVersion>False</SpecificVersion>
81-
<HintPath>$(ProgramFiles)\SDL\SDL Trados Studio\Studio3\Sdl.LanguagePlatform.TranslationMemory.dll</HintPath>
87+
<HintPath>..\..\..\..\..\..\Program Files (x86)\SDL\SDL Trados Studio\Studio5\Sdl.LanguagePlatform.TranslationMemory.dll</HintPath>
8288
</Reference>
8389
<Reference Include="Sdl.LanguagePlatform.TranslationMemoryApi, Version=1.6.0.0, Culture=neutral, PublicKeyToken=c28cdb26c445c888, processorArchitecture=MSIL">
8490
<SpecificVersion>False</SpecificVersion>
85-
<HintPath>$(ProgramFiles)\SDL\SDL Trados Studio\Studio3\Sdl.LanguagePlatform.TranslationMemoryApi.dll</HintPath>
91+
<HintPath>..\..\..\..\..\..\Program Files (x86)\SDL\SDL Trados Studio\Studio5\Sdl.LanguagePlatform.TranslationMemoryApi.dll</HintPath>
8692
</Reference>
8793
<Reference Include="System" />
8894
<Reference Include="System.Core">
@@ -105,12 +111,12 @@
105111
<DependentUpon>OpenNMTConfDialog.cs</DependentUpon>
106112
</Compile>
107113
<Compile Include="RestClient.cs" />
108-
<Compile Include="ListTranslationOptions.cs" />
109-
<Compile Include="ListTranslationProvider.cs" />
110-
<Compile Include="ListTranslationProviderElementVisitor.cs" />
111-
<Compile Include="ListTranslationProviderFactory.cs" />
112-
<Compile Include="ListTranslationProviderWinFormsUI.cs" />
113-
<Compile Include="ListTranslationProviderLanguageDirection.cs" />
114+
<Compile Include="OpenNMTTranslationOptions.cs" />
115+
<Compile Include="OpenNMTTranslationProvider.cs" />
116+
<Compile Include="OpenNMTTranslationProviderElementVisitor.cs" />
117+
<Compile Include="OpenNMTTranslationProviderFactory.cs" />
118+
<Compile Include="OpenNMTTranslationProviderWinFormsUI.cs" />
119+
<Compile Include="OpenNMTTranslationProviderLanguageDirection.cs" />
114120
<Compile Include="PluginResources.Designer.cs">
115121
<AutoGen>True</AutoGen>
116122
<DesignTime>True</DesignTime>
@@ -168,6 +174,7 @@
168174
</BootstrapperPackage>
169175
</ItemGroup>
170176
<ItemGroup>
177+
<None Include="app.config" />
171178
<None Include="key.snk" />
172179
<None Include="packages.config" />
173180
</ItemGroup>
@@ -177,9 +184,16 @@
177184
<PropertyGroup>
178185
<ApplicationIcon>
179186
</ApplicationIcon>
187+
<PluginDeploymentPath>$(AppData)\SDL\SDL Trados Studio\14\Plugins</PluginDeploymentPath>
180188
</PropertyGroup>
181189
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
182-
<Import Project="C:\Program Files (x86)\MSBuild\SDL\SDLTradosStudio\11\Sdl.Core.PluginFramework.Build.targets" />
190+
<Import Project="packages\Sdl.Core.PluginFramework.Build.15.0.2\build\net45\Sdl.Core.PluginFramework.Build.targets" Condition="Exists('packages\Sdl.Core.PluginFramework.Build.15.0.2\build\net45\Sdl.Core.PluginFramework.Build.targets')" />
191+
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
192+
<PropertyGroup>
193+
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
194+
</PropertyGroup>
195+
<Error Condition="!Exists('packages\Sdl.Core.PluginFramework.Build.15.0.2\build\net45\Sdl.Core.PluginFramework.Build.targets')" Text="$([System.String]::Format('$(ErrorText)', 'packages\Sdl.Core.PluginFramework.Build.15.0.2\build\net45\Sdl.Core.PluginFramework.Build.targets'))" />
196+
</Target>
183197
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
184198
Other similar extension points exist, see Microsoft.Common.targets.
185199
<Target Name="BeforeBuild">

0 commit comments

Comments
 (0)