Skip to content

Commit 032602d

Browse files
authored
Fix CI to account for removal of bin directory. (#385)
1 parent cb6b9d8 commit 032602d

File tree

4 files changed

+3
-83
lines changed

4 files changed

+3
-83
lines changed

.ci/ci.yml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,8 @@ stages:
6767
Write-Verbose -Verbose "Importing PSPackageProject from: $modPath"
6868
Import-Module -Name $modPath -Force
6969
#
70-
# First build for netstandard2.0 framework
70+
# Build for netstandard2.0 framework
7171
$(Build.SourcesDirectory)/build.ps1 -Build -Clean -BuildConfiguration Release -BuildFramework 'netstandard2.0'
72-
# Next build for net472 framework
73-
$(Build.SourcesDirectory)/build.ps1 -Build -BuildConfiguration Release -BuildFramework 'net472'
7472
displayName: Build and publish artifact
7573
7674
- pwsh: |

.ci/ci_auto.yml

Lines changed: 1 addition & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,8 @@ stages:
7373
Write-Verbose -Verbose "Importing PSPackageProject from: $modPath"
7474
Import-Module -Name $modPath -Force
7575
#
76-
# First build for netstandard2.0 framework
76+
# Build for netstandard2.0 framework
7777
$(Build.SourcesDirectory)/build.ps1 -Build -Clean -BuildConfiguration Release -BuildFramework 'netstandard2.0'
78-
# Next build for net472 framework
79-
$(Build.SourcesDirectory)/build.ps1 -Build -BuildConfiguration Release -BuildFramework 'net472'
8078
displayName: Build and publish artifact
8179
8280
- pwsh: |
@@ -112,12 +110,6 @@ stages:
112110
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "DscResources") -Dest $createdSignSrcPath -Recurse -Force -Verbose
113111
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "Modules") -Dest $createdSignSrcPath -Recurse -Force -Verbose
114112
115-
$net472Path = Join-Path -Path $createdSignSrcPath -ChildPath "net472"
116-
if (! (Test-Path -Path $net472Path)) {
117-
$null = New-Item -Path $net472Path -ItemType Directory -Verbose
118-
}
119-
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "net472\PowerShellGet.*") -Dest $net472Path -Force -Verbose
120-
121113
$netStandardPath = Join-Path -Path $createdSignSrcPath -ChildPath "netstandard2.0"
122114
if (! (Test-Path -Path $netStandardPath)) {
123115
$null = New-Item -Path $netStandardPath -ItemType Directory -Verbose
@@ -186,21 +178,6 @@ stages:
186178
if (! (Test-Path -Path $thirdPartySignSrcPath)) {
187179
$null = New-Item -Path $thirdPartySignSrcPath -ItemType Directory -Verbose
188180
}
189-
190-
# Net472 directory
191-
$net472Path = Join-Path -Path $thirdPartySignSrcPath -ChildPath "net472"
192-
if (! (Test-Path -Path $net472Path)) {
193-
$null = New-Item -Path $net472Path -ItemType Directory -Verbose
194-
}
195-
Get-ChildItem -Path (Join-Path -Path $srcPath -ChildPath "net472") -Filter '*.dll' | Foreach-Object {
196-
if ($_.Name -ne 'PowerShellGet.dll') {
197-
$sig = Get-AuthenticodeSignature -FilePath $_.FullName
198-
if ($sig.Status -ne 'Valid' -or $sig.SignerCertificate.Subject -notlike '*Microsoft*' -or $sig.SignerCertificate.Issuer -notlike '*Microsoft Code Signing PCA*') {
199-
# Copy for third party signing
200-
Copy-Item -Path $_.FullName -Dest $net472Path -Force -Verbose
201-
}
202-
}
203-
}
204181
205182
# NetStandard directory
206183
$netStandardPath = Join-Path -Path $thirdPartySignSrcPath -ChildPath "netstandard2.0"
@@ -256,21 +233,6 @@ stages:
256233
# en-US
257234
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "en-US") -Dest $signOutPath -Recurse
258235
259-
# Net472 directory
260-
$net472SignedOutPath = Join-Path -Path $signOutPath -ChildPath "net472"
261-
if (! (Test-Path -Path $net472SignedOutPath)) {
262-
$null = New-Item -Path $net472SignedOutPath -ItemType Directory -Verbose
263-
}
264-
Get-ChildItem -Path (Join-Path -Path $srcPath -ChildPath "net472") -Filter '*.dll' | Foreach-Object {
265-
if ($_.Name -ne 'PowerShellGet.dll') {
266-
$sig = Get-AuthenticodeSignature -FilePath $_.FullName
267-
if ($sig.Status -eq 'Valid' -and ($sig.SignerCertificate.Subject -like '*Microsoft*' -and $sig.SignerCertificate.Issuer -like '*Microsoft Code Signing PCA*')) {
268-
# Copy already signed files directly to output
269-
Copy-Item -Path $_.FullName -Dest $net472SignedOutPath -Force -Verbose
270-
}
271-
}
272-
}
273-
274236
# NetStandard directory
275237
$netStandardSignedOutPath = Join-Path -Path $signOutPath -ChildPath "netstandard2.0"
276238
if (! (Test-Path -Path $netStandardSignedOutPath)) {

.ci/ci_release.yml

Lines changed: 1 addition & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -72,10 +72,8 @@ stages:
7272
Write-Verbose -Verbose "Importing PSPackageProject from: $modPath"
7373
Import-Module -Name $modPath -Force
7474
#
75-
# First build for netstandard2.0 framework
75+
# Build for netstandard2.0 framework
7676
$(Build.SourcesDirectory)/build.ps1 -Build -Clean -BuildConfiguration Release -BuildFramework 'netstandard2.0'
77-
# Next build for net472 framework
78-
$(Build.SourcesDirectory)/build.ps1 -Build -BuildConfiguration Release -BuildFramework 'net472'
7977
displayName: Build and publish artifact
8078
8179
- pwsh: |
@@ -111,12 +109,6 @@ stages:
111109
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "DscResources") -Dest $createdSignSrcPath -Recurse -Force -Verbose
112110
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "Modules") -Dest $createdSignSrcPath -Recurse -Force -Verbose
113111
114-
$net472Path = Join-Path -Path $createdSignSrcPath -ChildPath "net472"
115-
if (! (Test-Path -Path $net472Path)) {
116-
$null = New-Item -Path $net472Path -ItemType Directory -Verbose
117-
}
118-
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "net472\PowerShellGet.*") -Dest $net472Path -Force -Verbose
119-
120112
$netStandardPath = Join-Path -Path $createdSignSrcPath -ChildPath "netstandard2.0"
121113
if (! (Test-Path -Path $netStandardPath)) {
122114
$null = New-Item -Path $netStandardPath -ItemType Directory -Verbose
@@ -184,21 +176,6 @@ stages:
184176
if (! (Test-Path -Path $thirdPartySignSrcPath)) {
185177
$null = New-Item -Path $thirdPartySignSrcPath -ItemType Directory -Verbose
186178
}
187-
188-
# Net472 directory
189-
$net472Path = Join-Path -Path $thirdPartySignSrcPath -ChildPath "net472"
190-
if (! (Test-Path -Path $net472Path)) {
191-
$null = New-Item -Path $net472Path -ItemType Directory -Verbose
192-
}
193-
Get-ChildItem -Path (Join-Path -Path $srcPath -ChildPath "net472") -Filter '*.dll' | Foreach-Object {
194-
if ($_.Name -ne 'PowerShellGet.dll') {
195-
$sig = Get-AuthenticodeSignature -FilePath $_.FullName
196-
if ($sig.Status -ne 'Valid' -or $sig.SignerCertificate.Subject -notlike '*Microsoft*' -or $sig.SignerCertificate.Issuer -notlike '*Microsoft Code Signing PCA*') {
197-
# Copy for third party signing
198-
Copy-Item -Path $_.FullName -Dest $net472Path -Force -Verbose
199-
}
200-
}
201-
}
202179
203180
# NetStandard directory
204181
$netStandardPath = Join-Path -Path $thirdPartySignSrcPath -ChildPath "netstandard2.0"
@@ -254,21 +231,6 @@ stages:
254231
# en-US
255232
Copy-Item -Path (Join-Path -Path $srcPath -ChildPath "en-US") -Dest $signOutPath -Recurse
256233
257-
# Net472 directory
258-
$net472SignedOutPath = Join-Path -Path $signOutPath -ChildPath "net472"
259-
if (! (Test-Path -Path $net472SignedOutPath)) {
260-
$null = New-Item -Path $net472SignedOutPath -ItemType Directory -Verbose
261-
}
262-
Get-ChildItem -Path (Join-Path -Path $srcPath -ChildPath "net472") -Filter '*.dll' | Foreach-Object {
263-
if ($_.Name -ne 'PowerShellGet.dll') {
264-
$sig = Get-AuthenticodeSignature -FilePath $_.FullName
265-
if ($sig.Status -eq 'Valid' -and ($sig.SignerCertificate.Subject -like '*Microsoft*' -and $sig.SignerCertificate.Issuer -like '*Microsoft Code Signing PCA*')) {
266-
# Copy already signed files directly to output
267-
Copy-Item -Path $_.FullName -Dest $net472SignedOutPath -Force -Verbose
268-
}
269-
}
270-
}
271-
272234
# NetStandard directory
273235
$netStandardSignedOutPath = Join-Path -Path $signOutPath -ChildPath "netstandard2.0"
274236
if (! (Test-Path -Path $netStandardSignedOutPath)) {

doBuild.ps1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,6 @@ function DoBuild
2020
# Copy module script files
2121
Write-Verbose -Verbose "Copy-Item ${SrcPath}/${ModuleName}.psd1 to $BuildOutPath"
2222
Copy-Item -Path "${SrcPath}/${ModuleName}.psd1" -Dest "$BuildOutPath" -Force
23-
Write-Verbose -Verbose "Copy Item ${SrcPath}/PSModule.psm1 to $BuildOutPath"
24-
Copy-Item -Path "${SrcPath}/PSModule.psm1" -Dest "$BuildOutPath" -Force
2523

2624
#Copy module format ps1xml file
2725
Write-Verbose -Verbose -Message "Copy-Item ${SrcPath}/${FormatFileName}.ps1xml to $BuildOutPath"

0 commit comments

Comments
 (0)