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

Replace the provider keyword with the extension keyword #14379

Merged
merged 3 commits into from
Jun 24, 2024

Conversation

shenglol
Copy link
Contributor

@shenglol shenglol commented Jun 20, 2024

As the first step of addressing #14374, this PR replaces the provider keyword with the extension keyword. Using the provider keyword will now trigger a warning diagnostic with a code fix to assist users in migrating to the new keyword.

To reduce the scope of this PR, the use of provider within the Bicep CLI, Bicep configuration, and the codebase will be replaced separately in subsequent PRs.

Closes #14378.

Microsoft Reviewers: Open in CodeFlow

Copy link
Contributor

github-actions bot commented Jun 20, 2024

Test this change out locally with the following install scripts (Action run 9650842308)

VSCode
  • Mac/Linux
    bash <(curl -Ls https://aka.ms/bicep/nightly-vsix.sh) --run-id 9650842308
  • Windows
    iex "& { $(irm https://aka.ms/bicep/nightly-vsix.ps1) } -RunId 9650842308"
Azure CLI
  • Mac/Linux
    bash <(curl -Ls https://aka.ms/bicep/nightly-cli.sh) --run-id 9650842308
  • Windows
    iex "& { $(irm https://aka.ms/bicep/nightly-cli.ps1) } -RunId 9650842308"

Copy link
Contributor

github-actions bot commented Jun 20, 2024

Dotnet Test Results

    72 files   -     36      72 suites   - 36   22m 17s ⏱️ - 10m 1s
10 891 tests  -     20  10 890 ✅  -     20  1 💤 ±0  0 ❌ ±0 
25 678 runs   - 12 835  25 676 ✅  - 12 834  2 💤  - 1  0 ❌ ±0 

Results for commit ce75a9c. ± Comparison against base commit e307d17.

♻️ This comment has been updated with latest results.

@@ -23,7 +23,7 @@ public class CentralizedProviderVersionManagementTests : TestBase
public void ProvidersConfig_SupportForConfigManagedProviderDeclarationSyntax_When_ProviderIsBuiltIn(string providerIdentifier, bool shouldSucceed, (string code, DiagnosticLevel level, string message)[] expectedDiagnostics)
{
var result = CompilationHelper.Compile(Services, @$"
provider {providerIdentifier}
extension {providerIdentifier}
Copy link
Contributor

Choose a reason for hiding this comment

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

As you mentioned in the PR description, will providerIdentifier be changed in another PR?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, this is tracked by #14375.

@anthony-c-martin
Copy link
Member

@rynowak fyi you already missed out on being able to use provider :)

@rynowak
Copy link
Contributor

rynowak commented Jun 22, 2024

@rynowak fyi you already missed out on being able to use provider :)

Good change 👍 The term provider is already too overloaded/generic.

@rynowak
Copy link
Contributor

rynowak commented Jun 24, 2024

/cc @shruthikumar

@shenglol shenglol merged commit 785c737 into main Jun 24, 2024
44 checks passed
@shenglol shenglol deleted the shenglol/provider-to-extension branch June 24, 2024 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Replace the provider keyword with the extension keyword
4 participants