From 1438bc60b9243ce27cda94ba37071771b88b85d7 Mon Sep 17 00:00:00 2001 From: TheCakeIsNaOH Date: Fri, 12 Aug 2022 17:07:30 -0500 Subject: [PATCH] (#798) Add pin package option to tab completion --- src/chocolatey.resources/helpers/ChocolateyTabExpansion.ps1 | 2 +- .../infrastructure.app/commands/ChocolateyExportCommand.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/chocolatey.resources/helpers/ChocolateyTabExpansion.ps1 b/src/chocolatey.resources/helpers/ChocolateyTabExpansion.ps1 index 2a6085299f..bcb3d8bb51 100644 --- a/src/chocolatey.resources/helpers/ChocolateyTabExpansion.ps1 +++ b/src/chocolatey.resources/helpers/ChocolateyTabExpansion.ps1 @@ -68,7 +68,7 @@ $commandOptions = @{ download = "--internalize --internalize-all-urls --ignore-dependencies --installed-packages --ignore-unfound-packages --resources-location='' --download-location='' --outputdirectory='' --source='' --version='' --prerelease --user='' --password='' --cert='' --certpassword='' --append-use-original-location --recompile --disable-package-repository-optimizations -? --use-self-service" + $allcommands sync = "--output-directory='' --id='' --package-id='' -? --use-self-service" + $allcommands optimize = "--deflate-nupkg-only --id='' -? --use-self-service" + $allcommands - export = "--include-version-numbers --output-file-path='' -?" + $allcommands + export = "--include-version-numbers --output-file-path='' --include-remembered-arguments -?" + $allcommands template = "--name=''" + $allcommands } diff --git a/src/chocolatey/infrastructure.app/commands/ChocolateyExportCommand.cs b/src/chocolatey/infrastructure.app/commands/ChocolateyExportCommand.cs index aa637d4bef..d26e9fc665 100644 --- a/src/chocolatey/infrastructure.app/commands/ChocolateyExportCommand.cs +++ b/src/chocolatey/infrastructure.app/commands/ChocolateyExportCommand.cs @@ -192,7 +192,7 @@ public void run(ChocolateyConfiguration configuration) if (configuration.ExportCommand.IncludeRememberedPackageArguments) { - var pkgInfo = _packageInfoService.get_package_information(packageResult.Package); + var pkgInfo = _packageInfoService.get_package_information(packageResult.PackageMetadata); configuration.Features.UseRememberedArgumentsForUpgrades = true; _nugetService.set_package_config_for_upgrade(configuration, pkgInfo);