Skip to content

Commit 2e17a06

Browse files
CopilotT-Gro
andcommitted
Revert Salsa project changes to avoid Microsoft.CodeAnalysis version conflicts
Co-authored-by: T-Gro <46543583+T-Gro@users.noreply.github.com>
1 parent 7eafa28 commit 2e17a06

File tree

3 files changed

+21
-16
lines changed

3 files changed

+21
-16
lines changed

tests/FSharp.Test.Utilities/FSharp.Test.Utilities.fsproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@
9595
<InternalsVisibleTo Include="LanguageServiceProfiling" />
9696
<InternalsVisibleTo Include="FSharp.Compiler.Benchmarks" />
9797
<InternalsVisibleTo Include="FSharp.Editor.Tests" />
98-
<InternalsVisibleTo Include="VisualFSharp.Salsa" />
9998
</ItemGroup>
10099

101100
<ItemGroup Condition="'$(TargetFramework)' != '$(FSharpNetCoreProductTargetFramework)'">

vsintegration/tests/Salsa/VisualFSharp.Salsa.fsproj

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
</ItemGroup>
1717

1818
<ItemGroup>
19-
<Compile Include="$(FSharpSourcesRoot)\Compiler\Utilities\NullnessShims.fs" />
19+
<Compile Include="$(FSharpSourcesRoot)\Compiler\Utilities\NullnessShims.fs"/>
2020
<EmbeddedText Include="$(FSharpSourcesRoot)\Compiler\Facilities\UtilsStrings.txt" />
2121
<Compile Include="$(FSharpSourcesRoot)\Compiler\Facilities\CompilerLocation.fs">
2222
<Link>CompilerLocation.fs</Link>
@@ -34,7 +34,6 @@
3434
<ProjectReference Include="$(FSharpSourcesRoot)\FSharp.Core\FSharp.Core.fsproj" />
3535
<ProjectReference Include="$(FSharpSourcesRoot)\FSharp.Build\FSharp.Build.fsproj" />
3636
<ProjectReference Include="$(FSharpSourcesRoot)\Compiler\FSharp.Compiler.Service.fsproj" />
37-
<ProjectReference Include="..\..\..\tests\FSharp.Test.Utilities\FSharp.Test.Utilities.fsproj" />
3837
<ProjectReference Include="..\..\src\FSharp.Editor\FSharp.Editor.fsproj" />
3938
<ProjectReference Include="..\..\src\FSharp.LanguageService.Base\FSharp.LanguageService.Base.csproj" />
4039
<ProjectReference Include="..\..\src\FSharp.LanguageService\FSharp.LanguageService.fsproj" />
@@ -52,11 +51,22 @@
5251

5352
<ItemGroup>
5453
<PackageReference Include="Microsoft.VisualStudio.Editor" Version="$(MicrosoftVisualStudioEditorVersion)" />
54+
<PackageReference Include="Microsoft.VisualStudio.Interop" Version="$(MicrosoftVisualStudioInteropVersion)" PrivateAssets="all" ExcludeAssets="runtime;contentFiles;build;analyzers;native" />
5555
<PackageReference Include="Microsoft.VisualStudio.Designer.Interfaces" Version="$(MicrosoftVisualStudioDesignerInterfacesVersion)" />
56+
<PackageReference Include="Microsoft.VisualStudio.GraphModel" Version="$(MicrosoftVisualStudioGraphModelVersion)" />
57+
<PackageReference Include="Microsoft.VisualStudio.ImageCatalog" Version="$(MicrosoftVisualStudioImageCatalogVersion)" />
5658
<PackageReference Include="Microsoft.VisualStudio.Platform.VSEditor" Version="$(MicrosoftVisualStudioPlatformVSEditorVersion)" />
59+
<PackageReference Include="Microsoft.VisualStudio.ProjectAggregator" Version="$(MicrosoftVisualStudioProjectAggregatorVersion)" />
60+
<PackageReference Include="Microsoft.VisualStudio.Shell.15.0" Version="$(MicrosoftVisualStudioShell150Version)" />
5761
<PackageReference Include="Microsoft.VisualStudio.Shell.Design" Version="$(MicrosoftVisualStudioShellDesignVersion)" />
62+
<PackageReference Include="Microsoft.VisualStudio.Shell.Framework" Version="$(MicrosoftVisualStudioShellFrameworkVersion)" />
5863
<PackageReference Include="Microsoft.Internal.VisualStudio.Shell.Framework" Version="$(MicrosoftInternalVisualStudioShellFrameworkVersion)" />
64+
<PackageReference Include="Microsoft.VisualStudio.Text.Data" Version="$(MicrosoftVisualStudioTextDataVersion)" />
65+
<PackageReference Include="Microsoft.VisualStudio.Text.Internal" Version="$(MicrosoftVisualStudioTextInternalVersion)" />
5966
<PackageReference Include="Microsoft.VisualStudio.Threading" Version="$(MicrosoftVisualStudioThreadingVersion)" />
67+
<PackageReference Include="Microsoft.VisualStudio.Utilities" Version="$(MicrosoftVisualStudioUtilitiesVersion)" />
68+
<PackageReference Include="Microsoft.VisualStudio.Validation" Version="$(MicrosoftVisualStudioValidationVersion)" PrivateAssets="all" ExcludeAssets="runtime;contentFiles;build;analyzers;native" />
69+
<PackageReference Include="Newtonsoft.Json" Version="$(NewtonsoftJsonVersion)" />
6070
<PackageReference Include="XUnit" Version="$(XUnitVersion)" />
6171
</ItemGroup>
6272

vsintegration/tests/Salsa/VsMocks.fs

Lines changed: 9 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1651,19 +1651,15 @@ module internal VsActual =
16511651
member public _.JoinableTaskContext : JoinableTaskContext = jtc
16521652

16531653
let vsInstallDir =
1654-
// Use centralized VS installation discovery with graceful fallback
1655-
match FSharp.Test.VSInstallDiscovery.tryGetVSInstallDir () with
1656-
| Some dir -> dir
1657-
| None ->
1658-
// Fallback to legacy behavior for backward compatibility
1659-
let vsvar =
1660-
let var = Environment.GetEnvironmentVariable("VS170COMNTOOLS")
1661-
if String.IsNullOrEmpty var then
1662-
Environment.GetEnvironmentVariable("VSAPPIDDIR")
1663-
else
1664-
var
1665-
if String.IsNullOrEmpty vsvar then failwith "VS170COMNTOOLS and VSAPPIDDIR environment variables not found."
1666-
Path.Combine(vsvar, "..")
1654+
// use the environment variable to find the VS installdir
1655+
let vsvar =
1656+
let var = Environment.GetEnvironmentVariable("VS170COMNTOOLS")
1657+
if String.IsNullOrEmpty var then
1658+
Environment.GetEnvironmentVariable("VSAPPIDDIR")
1659+
else
1660+
var
1661+
if String.IsNullOrEmpty vsvar then failwith "VS170COMNTOOLS and VSAPPIDDIR environment variables not found."
1662+
Path.Combine(vsvar, "..")
16671663

16681664
let CreateEditorCatalog() =
16691665
let thisAssembly = Assembly.GetExecutingAssembly().Location

0 commit comments

Comments
 (0)