From c5eff5ff0661e8229617617b1e437fa2e28dd960 Mon Sep 17 00:00:00 2001 From: Amber Erickson Date: Wed, 13 Sep 2023 16:10:47 -0700 Subject: [PATCH 1/3] Change 'CompatPowerShellGet' to 'PowerShellGet' --- .ci/releaseBuild.yml | 22 +++++++++++----------- CHANGELOG.md | 6 ++++++ README.md | 24 ++++++++++++------------ SignConfig.xml | 6 +++--- src/CompatPowerShellGet.psd1 | 16 +++++++++------- 5 files changed, 41 insertions(+), 33 deletions(-) diff --git a/.ci/releaseBuild.yml b/.ci/releaseBuild.yml index 49941fc..505ce63 100644 --- a/.ci/releaseBuild.yml +++ b/.ci/releaseBuild.yml @@ -1,5 +1,5 @@ # The name of the build that will be seen in mscodehub -name: CompatPowerShellget-Release-$(Build.BuildId) +name: PowerShellget-Release-$(Build.BuildId) # how is the build triggered # since this is a release build, no trigger as it's a manual release trigger: none @@ -38,7 +38,7 @@ stages: - ImageOverride -equals PSMMS2019-Secure jobs: - job: Build_Job - displayName: Build Microsoft.PowerShell.CompatPowerShellGet + displayName: Build Microsoft.PowerShell.PowerShellGet # note the variable reference to ESRP. # this must be created in Project -> Pipelines -> Library -> VariableGroups # where it describes the link to the SigningServer @@ -49,14 +49,14 @@ stages: # these are setting vso variables which will be persisted between stages - pwsh: | - $signSrcPath = "$(Build.SourcesDirectory)/CompatPowerShellGet/src" + $signSrcPath = "$(Build.SourcesDirectory)/PowerShellGet/src" dir # Set signing src path variable $vstsCommandString = "vso[task.setvariable variable=signSrcPath]${signSrcPath}" Write-Host "sending " + $vstsCommandString Write-Host "##$vstsCommandString" - $signOutPath = "$(Build.SourcesDirectory)/OSS_Microsoft_CompatPowerShellGet/signed/CompatPowerShellGet" + $signOutPath = "$(Build.SourcesDirectory)/OSS_Microsoft_CompatPowerShellGet/signed/PowerShellGet" $null = New-Item -ItemType Directory -Path $signOutPath # Set signing out path variable $vstsCommandString = "vso[task.setvariable variable=signOutPath]${signOutPath}" @@ -69,7 +69,7 @@ stages: Write-Host "##$vstsCommandString" # Get version and create a variable - $moduleData = Import-PowerShellDataFile "$(Build.SourcesDirectory)/CompatPowerShellGet/src/CompatPowerShellGet.psd1" + $moduleData = Import-PowerShellDataFile "$(Build.SourcesDirectory)/PowerShellGet/src/PowerShellGet.psd1" $moduleVersion = $moduleData.ModuleVersion $vstsCommandString = "vso[task.setvariable variable=moduleVersion]${moduleVersion}" Write-Host "sending " + $vstsCommandString @@ -112,7 +112,7 @@ stages: - pwsh: | $nupkgPath = "$(localRepo)" - $artifactName = "CompatPowerShellGet" + $artifactName = "PowerShellGet" Write-Host "##vso[artifact.upload containerfolder=$artifactName;artifactname=$artifactName;]$nupkgPath" displayName: Upload module artifact @@ -137,7 +137,7 @@ stages: - template: script-module-compliance.yml@ComplianceRepo parameters: # component-governance - the path to sources - sourceScanPath: '$(Build.SourcesDirectory)/CompatPowerShellGet' + sourceScanPath: '$(Build.SourcesDirectory)/PowerShellGet' # TermCheck optionsRulesDBPath: '' optionsFTPath: '' @@ -157,26 +157,26 @@ stages: - ImageOverride -equals PSMMS2019-Secure jobs: - job: Publish_Job - displayName: Build Microsoft.PowerShell.CompatPowerShellGet + displayName: Build Microsoft.PowerShell.PowerShellGet steps: - checkout: self - task: DownloadPipelineArtifact@2 displayName: 'Download PowerShellGet module artifacts' inputs: - artifact: CompatPowerShellGet + artifact: PowerShellGet patterns: '**/*.nupkg' downloadPath: '$(Pipeline.Workspace)/nuget' - pwsh: | - $package = (Get-ChildItem '$(Pipeline.Workspace)/nuget/CompatPowerShellGet.*.nupkg').FullName + $package = (Get-ChildItem '$(Pipeline.Workspace)/nuget/PowerShellGet.*.nupkg').FullName $vstsCommandString = "vso[task.setvariable variable=NugetPkgPath]${package}" Write-Host "sending " + $vstsCommandString Write-Host "##$vstsCommandString" displayName: 'Capture PowerShellGet module NuGet package path and set environment variable' - task: NuGetCommand@2 - displayName: 'Push CompatPowerShellGet module artifacts to PSGallery feed' + displayName: 'Push PowerShellGet module artifacts to PSGallery feed' inputs: command: push packagesToPush: '$(NugetPkgPath)' diff --git a/CHANGELOG.md b/CHANGELOG.md index 0e5c859..e0e216b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,10 @@ # Changelog +### 0.9.0 + +### 0.0.4 +* Changes +- Update module to be compatible with latest version of PowerShellGet (3.0.21-beta21) + ### 0.0.3 * Changes - Updated reference to PowerShellGet 'Url' parameter to 'Uri' to reflect changes made in PowerShellGet diff --git a/README.md b/README.md index 1dbb56e..68198a6 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ -# CompatPowerShellGet +# PowerShellGet -[![PowerShell Gallery - CompatPowerShellGet](https://img.shields.io/badge/PowerShell%20Gallery-PowerShellGet-blue.svg)](https://www.powershellgallery.com/packages/CompatPowerShellGet) -[![Minimum Supported PowerShell Version](https://img.shields.io/badge/PowerShell-3.0-blue.svg)](https://github.com/PowerShell/CompatPowerShellGet) +[![PowerShell Gallery - PowerShellGet](https://img.shields.io/badge/PowerShell%20Gallery-PowerShellGet-blue.svg)](https://www.powershellgallery.com/packages/PowerShellGet) +[![Minimum Supported PowerShell Version](https://img.shields.io/badge/PowerShell-5.1-blue.svg)](https://github.com/PowerShell/PowerShellGet) Introduction ============ -CompatPowerShellGet is a compatibility module that allows use of PowerShellGet 2.x (and below) cmdlet syntax with PowerShellGet 3.0 (and newer) functionality by making a best effort mapping between the cmdlet interfaces of both versions of the module.' +PowerShellGet v3 is a compatibility module that allows use of PowerShellGet 2.x (and below) cmdlet syntax with PSResourceGet functionality by making a best effort mapping between the cmdlet interfaces of both versions of the module.' This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/). For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) @@ -16,21 +16,21 @@ questions or comments. Documentation ============= -Documentation for CompatPowerShellGet has not yet been published, please +Documentation for PowerShellGet has not yet been published, please [Click here](https://docs.microsoft.com/powershell/module/PowerShellGet/?view=powershell-7) to reference the documentation for previous versions of PowerShellGet. Requirements ============ -- Windows PowerShell 3.0 or newer. +- Windows PowerShell 5.1 or newer. - PowerShell Core. -Get CompatPowerShellGet Module +Get PowerShellGet Module ======================== -Please refer to our [documentation](https://www.powershellgallery.com/packages/CompatPowerShellGet/) for the up-to-date version on how to get the CompatPowerShellGet Module. +Please refer to our [documentation](https://www.powershellgallery.com/packages/PowerShellGet/) for the up-to-date version on how to get the PowerShellGet Module. Get PowerShellGet Source @@ -38,17 +38,17 @@ Get PowerShellGet Source #### Steps * Obtain the source - - Download the latest source code from the release page (https://github.com/PowerShell/CompatPowerShellGet/releases) OR + - Download the latest source code from the release page (https://github.com/PowerShell/PowerShellGet/releases) OR - Clone the repository (needs git) ```powershell - git clone https://github.com/PowerShell/CompatPowerShellGet + git clone https://github.com/PowerShell/PowerShellGet ``` * Navigate to the source directory ```powershell -cd path/to/CompatPowerShellGet +cd path/to/PowerShellGet ``` * Import the module ```powershell -Import-Module src/CompatPowerShellGet +Import-Module src/PowerShellGet -Force ``` diff --git a/SignConfig.xml b/SignConfig.xml index 87b3d11..64d42f8 100644 --- a/SignConfig.xml +++ b/SignConfig.xml @@ -3,8 +3,8 @@ - - - + + + diff --git a/src/CompatPowerShellGet.psd1 b/src/CompatPowerShellGet.psd1 index b5cfe62..a330cf0 100644 --- a/src/CompatPowerShellGet.psd1 +++ b/src/CompatPowerShellGet.psd1 @@ -1,5 +1,5 @@ # -# Module manifest for module 'CompatPowerShellGet' +# Module manifest for module 'PowerShellGet' # # Generated by: americks # @@ -7,13 +7,13 @@ # @{ - RootModule = 'CompatPowerShellGet.psm1' - ModuleVersion = '0.0.4' + RootModule = 'PowerShellGet.psm1' + ModuleVersion = '0.9.0' GUID = '68ec3ec1-55bf-42f8-9add-d224e5c76548' Author = 'Microsoft Corporation' CompanyName = 'Microsoft Corporation' Copyright = '(c) Microsoft Corporation. All rights reserved.' - Description = 'CompatPowerShellGet is a compatibility module that allows use of PowerShellGet 2.x (and below) cmdlet syntax with PowerShellGet 3.0 (and newer) functionality by making a best effort mapping between the cmdlet interfaces of both versions of the module.' + Description = 'PowerShellGet is a compatibility module that allows use of PowerShellGet 2.x (and below) cmdlet syntax with PSResourceGet functionality by making a best effort mapping between the cmdlet interfaces of both versions of the module.' PowerShellVersion = '3.0' FunctionsToExport = @( "Find-Command", @@ -51,9 +51,11 @@ 'Mac', 'Windows') - LicenseUri = 'https://github.com/PowerShell/CompatPowerShellGet/blob/master/LICENSE' - ProjectUri = 'https://github.com/PowerShell/CompatPowerShellGet' + LicenseUri = 'https://github.com/PowerShell/PowerShellGet/blob/master/LICENSE' + ProjectUri = 'https://github.com/PowerShell/PowerShellGet' ReleaseNotes = @' +### 0.9.0 + ### 0.0.4 * Changes - Update module to be compatible with latest version of PowerShellGet (3.0.21-beta21) @@ -70,7 +72,7 @@ * Initial release ## For full history of release notes see changelog: -https://github.com/PowerShell/CompatPowerShellGet/blob/master/CHANGELOG.md +https://github.com/PowerShell/PowerShellGet/blob/master/CHANGELOG.md '@ } } From aa16919d6b98c08039274a5185e1064bef1bf779 Mon Sep 17 00:00:00 2001 From: Amber Erickson Date: Thu, 14 Sep 2023 08:48:12 -0700 Subject: [PATCH 2/3] Change file names --- src/{CompatPowerShellGet.psd1 => PowerShellGet.psd1} | 0 src/{CompatPowerShellGet.psm1 => PowerShellGet.psm1} | 0 2 files changed, 0 insertions(+), 0 deletions(-) rename src/{CompatPowerShellGet.psd1 => PowerShellGet.psd1} (100%) rename src/{CompatPowerShellGet.psm1 => PowerShellGet.psm1} (100%) diff --git a/src/CompatPowerShellGet.psd1 b/src/PowerShellGet.psd1 similarity index 100% rename from src/CompatPowerShellGet.psd1 rename to src/PowerShellGet.psd1 diff --git a/src/CompatPowerShellGet.psm1 b/src/PowerShellGet.psm1 similarity index 100% rename from src/CompatPowerShellGet.psm1 rename to src/PowerShellGet.psm1 From 2e7d0db4ba8e264e37bf74c6060bb8a08016eda4 Mon Sep 17 00:00:00 2001 From: alerickson <25858831+alerickson@users.noreply.github.com> Date: Thu, 14 Sep 2023 09:51:51 -0700 Subject: [PATCH 3/3] Update .ci/releaseBuild.yml --- .ci/releaseBuild.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.ci/releaseBuild.yml b/.ci/releaseBuild.yml index 361e50d..e86f604 100644 --- a/.ci/releaseBuild.yml +++ b/.ci/releaseBuild.yml @@ -1,5 +1,6 @@ # The name of the build that will be seen in mscodehub -name: PowerShellget-Release-$(Build.BuildId) +name: PowerShellGet-Release-$(Build.BuildId) + # how is the build triggered # since this is a release build, no trigger as it's a manual release trigger: none