Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convert SymbolSearchOptions to editorconfig options #74378

Merged
merged 4 commits into from
Jul 17, 2024

Conversation

tmat
Copy link
Member

@tmat tmat commented Jul 13, 2024

Changes dotnet_search_reference_assemblies to a supported editorconfig option (used by VS Code) and dotnet_unsupported_search_nuget_packages to an unsupported one.

SymbolSearchOptions were the last options on CodeActionOptions. Removing the former allows us to remove the latter.

@dotnet-issue-labeler dotnet-issue-labeler bot added Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead labels Jul 13, 2024
@tmat tmat changed the title Symbol search options Convert SymbolSearchOptions to editorconfig options Jul 13, 2024
@tmat tmat force-pushed the SymbolSearchOptions branch from 70d8272 to 728a2c9 Compare July 16, 2024 20:50
@tmat tmat marked this pull request as ready for review July 16, 2024 20:50
@tmat tmat requested a review from a team as a code owner July 16, 2024 20:50
@@ -46,31 +33,35 @@ internal abstract partial class AbstractAddPackageCodeFixProvider : CodeFixProvi

var workspaceServices = document.Project.Solution.Services;

var symbolSearchService = _symbolSearchService ?? workspaceServices.GetService<ISymbolSearchService>();
var installerService = _packageInstallerService ?? workspaceServices.GetService<IPackageInstallerService>();
if (workspaceServices.GetService<ISymbolSearchService>() is not { } symbolSearchService ||
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fwiw, i don't like not { } name to mix the retrival and null check. i'd prefer a distinct null check step.

IPackageInstallerService packageInstallerService = null,
ISymbolSearchService symbolSearchService = null)
: base(packageInstallerService, symbolSearchService)
protected AbstractAddSpecificPackageCodeFixProvider()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

feeel free to remove.


internal static class SymbolSearchOptionsStorage
{
private static readonly OptionGroup s_optionGroup = new(name: "symbol_search", description: FeaturesResources.Symbol_search);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe dotnet_symbol_search? what's the namign we're generally using for these groups?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"dotnet" is part of the option name. It ends up as dotnet.symbolSearch.searchReferenceAssemblies in VS Code after the transformations we do.

@tmat tmat merged commit a26c728 into dotnet:main Jul 17, 2024
25 checks passed
@tmat tmat deleted the SymbolSearchOptions branch July 17, 2024 17:58
@dotnet-policy-service dotnet-policy-service bot added this to the Next milestone Jul 17, 2024
@RikkiGibson RikkiGibson modified the milestones: Next, 17.12 P1 Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants