Skip to content

Commit bb43b26

Browse files
Merge pull request #138 from StartAutomating/PipeScriptWorkflowFix
Strongly Comparing Versions on Gallery Publish (#137)
2 parents 5756723 + ff4fe14 commit bb43b26

File tree

1 file changed

+26
-5
lines changed

1 file changed

+26
-5
lines changed

.github/workflows/TestAndPublish.yml

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -448,9 +448,9 @@ jobs:
448448
449449
if (-not $imported) { return }
450450
451-
$foundModule = try { Find-Module -Name $imported.Name -ErrorAction SilentlyContinue } catch {}
451+
$foundModule = try { Find-Module -Name $imported.Name -ErrorAction SilentlyContinue} catch {}
452452
453-
if ($foundModule -and $foundModule.Version -ge $imported.Version) {
453+
if ($foundModule -and (([Version]$foundModule.Version) -ge ([Version]$imported.Version))) {
454454
"::warning::Gallery Version of $moduleName is more recent ($($foundModule.Version) >= $($imported.Version))" | Out-Host
455455
} else {
456456
@@ -485,18 +485,39 @@ jobs:
485485
}
486486
}
487487
} @Parameters
488-
BuildModule:
488+
UsePiecemeal:
489+
runs-on: ubuntu-latest
490+
if: ${{ success() }}
491+
steps:
492+
- name: Check out repository
493+
uses: actions/checkout@v2
494+
- name: UsePiecemeal
495+
uses: StartAutomating/Piecemeal@main
496+
BuildPipeScript:
489497
runs-on: ubuntu-latest
490498
if: ${{ success() }}
491499
steps:
492500
- name: Check out repository
493501
uses: actions/checkout@v2
494502
- name: BuildPipeScript
495503
uses: StartAutomating/PipeScript@main
504+
RunEZOut:
505+
runs-on: ubuntu-latest
506+
if: ${{ success() }}
507+
steps:
508+
- name: Check out repository
509+
uses: actions/checkout@v2
496510
- name: UseEZOut
497511
uses: StartAutomating/EZOut@master
498-
- name: UsePiecemeal
499-
uses: StartAutomating/Piecemeal@main
512+
- name: Push Changes
513+
shell: pwsh
514+
run: git push; exit 0
515+
HelpOut:
516+
runs-on: ubuntu-latest
517+
if: ${{ success() }}
518+
steps:
519+
- name: Check out repository
520+
uses: actions/checkout@v2
500521
- name: UseHelpOut
501522
uses: StartAutomating/HelpOut@master
502523
env:

0 commit comments

Comments
 (0)