File tree Expand file tree Collapse file tree 2 files changed +16
-6
lines changed
Expand file tree Collapse file tree 2 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -52,10 +52,15 @@ $($gitHubEvent | ConvertTo-Json -Depth 100)
5252::endgroup::
5353"@ | Out-Host
5454
55- if ($env: GITHUB_ACTION_PATH ) {
55+ $PSD1Found = Get-ChildItem - Recurse - Filter " *.psd1" | Where-Object Name -eq ' PipeScript.psd1' | Select-Object - First 1
56+
57+ if ($PSD1Found ) {
58+ $PipeScriptModulePath = $PSD1Found
59+ Import-Module $psd1Path - Force - PassThru | Out-Host
60+ } elseif ($env: GITHUB_ACTION_PATH ) {
5661 $PipeScriptModulePath = Join-Path $env: GITHUB_ACTION_PATH ' PipeScript.psd1'
5762 if (Test-path $PipeScriptModulePath ) {
58- Import-Module $PipeScriptModulePath - Force - PassThru | Out-String
63+ Import-Module $PipeScriptModulePath - Force - PassThru | Out-Host
5964 } else {
6065 throw " PipeScript not found"
6166 }
Original file line number Diff line number Diff line change @@ -48,10 +48,10 @@ runs:
4848 shell : pwsh
4949 env :
5050 SkipBuild : ${{inputs.SkipBuild}}
51+ UserName : ${{inputs.UserName}}
5152 CommitMessage : ${{inputs.CommitMessage}}
52- PipeScript : ${{inputs.PipeScript}}
5353 UserEmail : ${{inputs.UserEmail}}
54- UserName : ${{inputs.UserName }}
54+ PipeScript : ${{inputs.PipeScript }}
5555 run : |
5656 $Parameters = @{}
5757 $Parameters.PipeScript = ${env:PipeScript}
@@ -120,10 +120,15 @@ runs:
120120 ::endgroup::
121121 "@ | Out-Host
122122
123- if ($env:GITHUB_ACTION_PATH) {
123+ $PSD1Found = Get-ChildItem -Recurse -Filter "*.psd1" | Where-Object Name -eq 'PipeScript.psd1' | Select-Object -First 1
124+
125+ if ($PSD1Found) {
126+ $PipeScriptModulePath = $PSD1Found
127+ Import-Module $psd1Path -Force -PassThru | Out-Host
128+ } elseif ($env:GITHUB_ACTION_PATH) {
124129 $PipeScriptModulePath = Join-Path $env:GITHUB_ACTION_PATH 'PipeScript.psd1'
125130 if (Test-path $PipeScriptModulePath) {
126- Import-Module $PipeScriptModulePath -Force -PassThru | Out-String
131+ Import-Module $PipeScriptModulePath -Force -PassThru | Out-Host
127132 } else {
128133 throw "PipeScript not found"
129134 }
You can’t perform that action at this time.
0 commit comments