From 141061ef9b767660e27541b5adad5fcc4f619a84 Mon Sep 17 00:00:00 2001 From: Billy O'Neal Date: Fri, 21 Jun 2024 15:54:03 -0700 Subject: [PATCH] Sign posh-vcpkg.psd1 (#1432) Just like posh-vcpkg.psm1 --- .../arch-independent-signing.signproj | 3 ++ azure-pipelines/signing.yml | 2 ++ scripts/posh-vcpkg.psd1 | 31 +++++++++++++++++++ vcpkg-init/mint-standalone-bundle.ps1 | 4 ++- 4 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 scripts/posh-vcpkg.psd1 diff --git a/azure-pipelines/arch-independent-signing.signproj b/azure-pipelines/arch-independent-signing.signproj index 0bc8963bf..a6c34a09a 100644 --- a/azure-pipelines/arch-independent-signing.signproj +++ b/azure-pipelines/arch-independent-signing.signproj @@ -29,6 +29,9 @@ Microsoft400 + + Microsoft400 + diff --git a/azure-pipelines/signing.yml b/azure-pipelines/signing.yml index 2c223d139..ce5935e06 100644 --- a/azure-pipelines/signing.yml +++ b/azure-pipelines/signing.yml @@ -187,6 +187,7 @@ extends: move "$(Build.BinariesDirectory)\scripts\applocal.ps1" "$(Build.ArtifactStagingDirectory)\staging\scripts\applocal.ps1" move "$(Build.BinariesDirectory)\scripts\addPoshVcpkgToPowershellProfile.ps1" "$(Build.ArtifactStagingDirectory)\staging\scripts\addPoshVcpkgToPowershellProfile.ps1" move "$(Build.BinariesDirectory)\scripts\posh-vcpkg.psm1" "$(Build.ArtifactStagingDirectory)\staging\scripts\posh-vcpkg.psm1" + move "$(Build.BinariesDirectory)\scripts\posh-vcpkg.psd1" "$(Build.ArtifactStagingDirectory)\staging\scripts\posh-vcpkg.psd1" move "$(Build.BinariesDirectory)\vcpkg-artifacts" "$(Build.ArtifactStagingDirectory)\staging\vcpkg-artifacts" displayName: 'Arrange Architecture-independent Files for Staging' - task: Powershell@2 @@ -437,6 +438,7 @@ extends: move "$(Build.ArtifactStagingDirectory)\stagingArchIndependent\scripts\applocal.ps1" "$(Build.ArtifactStagingDirectory)\drop\applocal.ps1" move "$(Build.ArtifactStagingDirectory)\stagingArchIndependent\scripts\addPoshVcpkgToPowershellProfile.ps1" "$(Build.ArtifactStagingDirectory)\drop\addPoshVcpkgToPowershellProfile.ps1" move "$(Build.ArtifactStagingDirectory)\stagingArchIndependent\scripts\posh-vcpkg.psm1" "$(Build.ArtifactStagingDirectory)\drop\posh-vcpkg.psm1" + move "$(Build.ArtifactStagingDirectory)\stagingArchIndependent\scripts\posh-vcpkg.psd1" "$(Build.ArtifactStagingDirectory)\drop\posh-vcpkg.psd1" move "$(Build.ArtifactStagingDirectory)\stagingGlibc\vcpkg-glibc" "$(Build.ArtifactStagingDirectory)\drop\vcpkg-glibc" move "$(Build.ArtifactStagingDirectory)\stagingMuslc\vcpkg-muslc" "$(Build.ArtifactStagingDirectory)\drop\vcpkg-muslc" move "$(Build.ArtifactStagingDirectory)\stagingArchIndependent\vcpkg-standalone-bundle.tar.gz" "$(Build.ArtifactStagingDirectory)\drop\vcpkg-standalone-bundle.tar.gz" diff --git a/scripts/posh-vcpkg.psd1 b/scripts/posh-vcpkg.psd1 new file mode 100644 index 000000000..3fb94fe7d --- /dev/null +++ b/scripts/posh-vcpkg.psd1 @@ -0,0 +1,31 @@ +@{ + +# Script module or binary module file associated with this manifest. +ModuleToProcess = 'posh-vcpkg.psm1' + +# Version number of this module. +ModuleVersion = '0.0.1' + +# ID used to uniquely identify this module +GUID = '948f02ab-fc99-4a53-8335-b6556eef129b' + +# Minimum version of the Windows PowerShell engine required by this module +PowerShellVersion = '5.0' + +FunctionsToExport = @('TabExpansion') +CmdletsToExport = @() +VariablesToExport = @() +AliasesToExport = @() + +# Private data to pass to the module specified in RootModule/ModuleToProcess. +# This may also contain a PSData hashtable with additional module metadata used by PowerShell. +PrivateData = +@{ + PSData = + @{ + # Tags applied to this module. These help with module discovery in online galleries. + Tags = @('vcpkg', 'tab', 'tab-completion', 'tab-expansion', 'tabexpansion') + } +} + +} diff --git a/vcpkg-init/mint-standalone-bundle.ps1 b/vcpkg-init/mint-standalone-bundle.ps1 index 8183794fb..0b9816311 100644 --- a/vcpkg-init/mint-standalone-bundle.ps1 +++ b/vcpkg-init/mint-standalone-bundle.ps1 @@ -52,7 +52,8 @@ $scripts_dependencies = @( $scripts_exclusions = @( 'buildsystems/msbuild/applocal.ps1', - 'posh-vcpkg/0.0.1/posh-vcpkg.psm1' + 'posh-vcpkg/0.0.1/posh-vcpkg.psm1', + 'posh-vcpkg/0.0.1/posh-vcpkg.psd1' ) if (Test-Path $TempDir) { @@ -102,6 +103,7 @@ try { Copy-Item -Path "$PSScriptRoot/vcpkg.targets" -Destination 'out/scripts/buildsystems/msbuild/vcpkg.targets' New-Item -Path 'out/scripts/posh-vcpkg/0.0.1' -ItemType 'Directory' -Force Copy-Item -Path "$ArchIndependentSignedFilesRoot/scripts/posh-vcpkg.psm1" -Destination 'out/scripts/posh-vcpkg/0.0.1/posh-vcpkg.psm1' + Copy-Item -Path "$ArchIndependentSignedFilesRoot/scripts/posh-vcpkg.psd1" -Destination 'out/scripts/posh-vcpkg/0.0.1/posh-vcpkg.psd1' Copy-Item -Path "$ArchIndependentSignedFilesRoot/vcpkg-artifacts" -Destination 'out/vcpkg-artifacts' -Recurse