Skip to content

Commit

Permalink
Merge pull request #731 from dlemstra/remove-some-of-the-new-credenti…
Browse files Browse the repository at this point in the history
…al-options
  • Loading branch information
clairernovotny authored Jun 25, 2024
2 parents df5506b + c5069e7 commit 1df56d5
Show file tree
Hide file tree
Showing 18 changed files with 0 additions and 208 deletions.
25 changes: 0 additions & 25 deletions src/Sign.Cli/AzureCredentialOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,6 @@ namespace Sign.Cli
{
internal sealed class AzureCredentialOptions
{
internal Option<string?> CredentialTypeOption { get; } = new Option<string?>(["--azure-credential-type", "-act"], Resources.CredentialTypeOptionDescription).FromAmong(
AzureCredentialType.AzureCli,
AzureCredentialType.Environment,
AzureCredentialType.ManagedIdentity);
internal Option<string?> TenantIdOption { get; } = new(["--azure-tenant-id", "-ati"], Resources.TenantIdOptionDescription);
internal Option<string?> ManagedIdentityClientIdOption = new(["--managed-identity-client-id", "-mici"], Resources.ManagedIdentityClientIdOptionDescription);
internal Option<string?> ManagedIdentityResourceIdOption = new(["--managed-identity-resource-id", "-miri"], Resources.ManagedIdentityResourceIdOptionDescription);
internal Option<bool?> ObsoleteManagedIdentityOption { get; } = new(["--azure-key-vault-managed-identity", "-kvm"], Resources.ManagedIdentityOptionDescription) { IsHidden = true };
Expand All @@ -27,8 +22,6 @@ internal sealed class AzureCredentialOptions

internal void AddOptionsToCommand(Command command)
{
command.AddOption(CredentialTypeOption);
command.AddOption(TenantIdOption);
command.AddOption(ManagedIdentityClientIdOption);
command.AddOption(ManagedIdentityResourceIdOption);
command.AddOption(ObsoleteManagedIdentityOption);
Expand All @@ -41,12 +34,6 @@ internal DefaultAzureCredentialOptions CreateDefaultAzureCredentialOptions(Parse
{
DefaultAzureCredentialOptions options = new();

string? tenantId = parseResult.GetValueForOption(TenantIdOption);
if (tenantId is not null)
{
options.TenantId = tenantId;
}

string? managedIdentityClientId = parseResult.GetValueForOption(ManagedIdentityClientIdOption);
if (managedIdentityClientId is not null)
{
Expand All @@ -59,18 +46,6 @@ internal DefaultAzureCredentialOptions CreateDefaultAzureCredentialOptions(Parse
options.ManagedIdentityResourceId = new ResourceIdentifier(managedIdentityResourceId);
}

string? credentialType = parseResult.GetValueForOption(CredentialTypeOption);
if (credentialType is not null)
{
options.ExcludeAzureCliCredential = credentialType != AzureCredentialType.AzureCli;
options.ExcludeAzureDeveloperCliCredential = true;
options.ExcludeAzurePowerShellCredential = true;
options.ExcludeEnvironmentCredential = credentialType != AzureCredentialType.Environment;
options.ExcludeManagedIdentityCredential = credentialType != AzureCredentialType.ManagedIdentity;
options.ExcludeVisualStudioCredential = true;
options.ExcludeWorkloadIdentityCredential = true;
}

return options;
}

Expand Down
13 changes: 0 additions & 13 deletions src/Sign.Cli/AzureCredentialType.cs

This file was deleted.

9 changes: 0 additions & 9 deletions src/Sign.Cli/Resources.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 0 additions & 3 deletions src/Sign.Cli/Resources.resx
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,6 @@
<data name="CodeCommandDescription" xml:space="preserve">
<value>Sign binaries and containers.</value>
</data>
<data name="CredentialTypeOptionDescription" xml:space="preserve">
<value>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</value>
</data>
<data name="DescriptionOptionDescription" xml:space="preserve">
<value>Description of the signing certificate.</value>
</data>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.cs.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Podepisovat binární soubory a kontejnery.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Popis podpisového certifikátu.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.de.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Signieren Sie Binärdateien und Container.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="translated">Azure-Anmeldeinformationstyp, der verwendet wird. Standardmäßig werden alle Typen außer interaktivem Browser, freigegebenem Token und Visual Studio Code verwendet.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Beschreibung des Signaturzertifikats.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.es.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Firmar archivos binarios y contenedores.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="translated">Tipo de credencial de Azure que se usará. El valor predeterminado es todos los tipos, excepto el explorador interactivo, el token compartido y el Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Descripción del certificado de firma.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.fr.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Signer les fichiers binaires et les conteneurs.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Description du certificat de signature.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.it.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Consente di firmare file binari e contenitori.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Descrizione del certificato di firma.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.ja.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">バイナリとコンテナーに署名します。</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">署名証明書の説明。</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.ko.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">이진 파일 및 컨테이너에 서명합니다.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="translated">사용할 Azure 자격 증명 형식입니다. 기본적으로 대화형 브라우저, 공유 토큰 및 Visual Studio Code를 제외한 모든 형식으로 설정됩니다.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">서명 인증서에 대한 설명입니다.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.pl.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Podpisz pliki binarne i kontenery.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Opis certyfikatu podpisywania.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.pt-BR.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Autenticar contêineres e binários.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Descrição do certificado de autenticação.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.ru.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">Подписывание двоичных файлов и контейнеров.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="translated">Тип учетных данных Azure, который будет использоваться. Это значение по умолчанию используется для всех типов, кроме интерактивного браузера, общего токена и Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">Описание сертификата для подписи</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.tr.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">İkili dosyaları ve kapsayıcıları imzalayın.</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">İmzalama sertifikasının açıklaması.</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.zh-Hans.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">对二进制文件和容器进行签名。</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="new">Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">签名证书的说明。</target>
Expand Down
5 changes: 0 additions & 5 deletions src/Sign.Cli/xlf/Resources.zh-Hant.xlf
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,6 @@
<target state="translated">簽署二進位檔和容器。</target>
<note />
</trans-unit>
<trans-unit id="CredentialTypeOptionDescription">
<source>Azure credential type that will be used. This defaults to all types except interactive browser, shared token and Visual Studio Code.</source>
<target state="translated">將使用的 Azure 認證類型。這預設為互動式瀏覽器、共用權杖和 Visual Studio Code 以外的所有類型。</target>
<note />
</trans-unit>
<trans-unit id="DescriptionOptionDescription">
<source>Description of the signing certificate.</source>
<target state="translated">簽署憑證的描述。</target>
Expand Down
Loading

0 comments on commit 1df56d5

Please sign in to comment.