Skip to content

Commit 5cec091

Browse files
🪲 [Fix]: Setting PowerShellVersion correctly after tests (#19)
## Description - Fix an issue where the version would be set incorrectly after tests. ## Type of change <!-- Use the check-boxes [x] on the options that are relevant. --> - [ ] 📖 [Docs] - [x] 🪲 [Fix] - [ ] 🩹 [Patch] - [ ] ⚠️ [Security fix] - [ ] 🚀 [Feature] - [ ] 🌟 [Breaking change] ## Checklist <!-- Use the check-boxes [x] on the options that are relevant. --> - [x] I have performed a self-review of my own code - [x] I have commented my code, particularly in hard-to-understand areas
1 parent 2a50441 commit 5cec091

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

.github/workflows/workflow.yml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -344,17 +344,18 @@ jobs:
344344
}
345345
Write-Host ($data | Format-Table | Out-String)
346346
347+
Set-ModuleManifest -Path $moduleManifestPath -PowerShellVersion '5.1'
348+
347349
if ($Desktop) {
348350
Add-ModuleManifestData -Path $moduleManifestPath -CompatiblePSEditions 'Desktop'
349351
Add-ModuleManifestData -Path $moduleManifestPath -Tags 'PSEdition_Desktop'
352+
} else {
353+
Set-ModuleManifest -Path $moduleManifestPath -PowerShellVersion '7.0'
350354
}
351355
352356
if ($Core) {
353357
Add-ModuleManifestData -Path $moduleManifestPath -CompatiblePSEditions 'Core'
354358
Add-ModuleManifestData -Path $moduleManifestPath -Tags 'PSEdition_Core'
355-
Set-ModuleManifest -Path $moduleManifestPath -PowerShellVersion '7.0'
356-
} else {
357-
Set-ModuleManifest -Path $moduleManifestPath -PowerShellVersion '5.1'
358359
}
359360
360361
if ($Linux) {

0 commit comments

Comments
 (0)