<PropertyGroup> <CopyLocalLockFileAssemblies>true</CopyLocalLockFileAssemblies> <IncludeAssemblyInVSIXContainer>true</IncludeAssemblyInVSIXContainer> <IncludeDebugSymbolsInVSIXContainer>true</IncludeDebugSymbolsInVSIXContainer> <IncludeDebugSymbolsInLocalVSIXDeployment>true</IncludeDebugSymbolsInLocalVSIXDeployment> </PropertyGroup> <Target Name="_ResolveCopyLocalNuGetPackagePdbs" Condition="$(CopyLocalLockFileAssemblies) == true" AfterTargets="ResolveReferences" BeforeTargets="GetVsixSourceItems"> <ItemGroup> <VSIXCopyLocalReferenceSourceItem Include="@(ReferenceCopyLocalPaths->'%(RootDir)%(Directory)%(Filename).pdb')" Condition="Exists('%(RootDir)%(Directory)%(Filename).pdb')" /> </ItemGroup> </Target>
參考地址:spa
https://stackoverflow.com/questions/19007964/how-to-include-debugging-symbols-to-vsix-packagedebug