Browse Source

Use VSIXSourceItem to add ILSpy distribution to VSIX after ResolveProjectReferences.

pull/2667/head
Siegfried Pammer 4 years ago
parent
commit
a2b1e9a6ca
  1. 31
      ILSpy.AddIn.VS2022/ILSpy.AddIn.VS2022.csproj
  2. 31
      ILSpy.AddIn/ILSpy.AddIn.csproj

31
ILSpy.AddIn.VS2022/ILSpy.AddIn.VS2022.csproj

@ -82,35 +82,26 @@
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup> </ItemGroup>
<!--
BEGIN WORKAROUND:
Nuget packages do not get added to the vsix automatically.
(related to https://github.com/icsharpcode/ILSpy/issues/511)
-->
<PropertyGroup> <PropertyGroup>
<ILSpyBuildPath>..\ILSpy\bin\$(Configuration)\net6.0-windows\</ILSpyBuildPath> <ILSpyBuildPath>..\ILSpy\bin\$(Configuration)\net6.0-windows\</ILSpyBuildPath>
</PropertyGroup> </PropertyGroup>
<Target Name="IncludeILSpyDistributionInVSIXSubFolder" AfterTargets="ResolveProjectReferences">
<ItemGroup>
<VSIXSourceItem Include="$(ILSpyBuildPath)zh-Hans\ILSpy.resources.dll;$(ILSpyBuildPath)zh-Hans\ILSpy.ReadyToRun.Plugin.resources.dll;">
<VSIXSubPath>\ILSpy\zh-Hans\</VSIXSubPath>
</VSIXSourceItem>
<VSIXSourceItem Include="$(ILSpyBuildPath)*.dll;$(ILSpyBuildPath)ILSpy.exe;$(ILSpyBuildPath)*.json">
<VSIXSubPath>\ILSpy</VSIXSubPath>
</VSIXSourceItem>
</ItemGroup>
</Target>
<ItemGroup> <ItemGroup>
<Content Include="$(OutputPath)Mono.Cecil.dll"> <Content Include="$(OutputPath)Mono.Cecil.dll">
<IncludeInVSIX>true</IncludeInVSIX> <IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\</VSIXSubPath> <VSIXSubPath>\</VSIXSubPath>
</Content> </Content>
</ItemGroup>
<!-- END WORKAROUND -->
<ItemGroup>
<Content Include="$(ILSpyBuildPath)*.dll;$(ILSpyBuildPath)ILSpy.exe;$(ILSpyBuildPath)*.json">
<IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\ILSpy</VSIXSubPath>
</Content>
</ItemGroup>
<ItemGroup>
<Content Include="$(ILSpyBuildPath)zh-Hans\ILSpy.resources.dll;$(ILSpyBuildPath)zh-Hans\ILSpy.ReadyToRun.Plugin.resources.dll;">
<IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\ILSpy\zh-Hans\</VSIXSubPath>
</Content>
<Content Include="ILSpy-Large.ico"> <Content Include="ILSpy-Large.ico">
<CopyToOutputDirectory>Always</CopyToOutputDirectory> <CopyToOutputDirectory>Always</CopyToOutputDirectory>
<IncludeInVSIX>true</IncludeInVSIX> <IncludeInVSIX>true</IncludeInVSIX>

31
ILSpy.AddIn/ILSpy.AddIn.csproj

@ -88,35 +88,26 @@
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup> </ItemGroup>
<!--
BEGIN WORKAROUND:
Nuget packages do not get added to the vsix automatically.
(related to https://github.com/icsharpcode/ILSpy/issues/511)
-->
<PropertyGroup> <PropertyGroup>
<ILSpyBuildPath>..\ILSpy\bin\$(Configuration)\net6.0-windows\</ILSpyBuildPath> <ILSpyBuildPath>..\ILSpy\bin\$(Configuration)\net6.0-windows\</ILSpyBuildPath>
</PropertyGroup> </PropertyGroup>
<Target Name="IncludeILSpyDistributionInVSIXSubFolder" AfterTargets="ResolveProjectReferences">
<ItemGroup>
<VSIXSourceItem Include="$(ILSpyBuildPath)zh-Hans\ILSpy.resources.dll;$(ILSpyBuildPath)zh-Hans\ILSpy.ReadyToRun.Plugin.resources.dll;">
<VSIXSubPath>\ILSpy\zh-Hans\</VSIXSubPath>
</VSIXSourceItem>
<VSIXSourceItem Include="$(ILSpyBuildPath)*.dll;$(ILSpyBuildPath)ILSpy.exe;$(ILSpyBuildPath)*.json">
<VSIXSubPath>\ILSpy</VSIXSubPath>
</VSIXSourceItem>
</ItemGroup>
</Target>
<ItemGroup> <ItemGroup>
<Content Include="$(OutputPath)Mono.Cecil.dll"> <Content Include="$(OutputPath)Mono.Cecil.dll">
<IncludeInVSIX>true</IncludeInVSIX> <IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\</VSIXSubPath> <VSIXSubPath>\</VSIXSubPath>
</Content> </Content>
</ItemGroup>
<!-- END WORKAROUND -->
<ItemGroup>
<Content Include="$(ILSpyBuildPath)*.dll;$(ILSpyBuildPath)ILSpy.exe;$(ILSpyBuildPath)*.json">
<IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\ILSpy</VSIXSubPath>
</Content>
</ItemGroup>
<ItemGroup>
<Content Include="$(ILSpyBuildPath)zh-Hans\ILSpy.resources.dll;$(ILSpyBuildPath)zh-Hans\ILSpy.ReadyToRun.Plugin.resources.dll;">
<IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\ILSpy\zh-Hans\</VSIXSubPath>
</Content>
<Content Include="ILSpy-Large.ico"> <Content Include="ILSpy-Large.ico">
<CopyToOutputDirectory>Always</CopyToOutputDirectory> <CopyToOutputDirectory>Always</CopyToOutputDirectory>
<IncludeInVSIX>true</IncludeInVSIX> <IncludeInVSIX>true</IncludeInVSIX>

Loading…
Cancel
Save