File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,11 +9,11 @@ function Add-GitHubActionsEnvVariable {
99 )
1010
1111 if ([string ]::IsNullOrWhiteSpace($Path )) {
12- throw " GitHub Actions environment file must not be empty."
12+ throw " GitHub Actions environment file path must not be empty."
1313 }
1414
1515 if ([string ]::IsNullOrWhiteSpace($Name )) {
16- throw " GitHub Actions environment variable names must not be empty."
16+ throw " GitHub Actions environment variable name must not be empty."
1717 }
1818
1919 $utf8NoBom = [System.Text.UTF8Encoding ]::new($false )
@@ -29,11 +29,11 @@ function Add-GitHubActionsPath {
2929 )
3030
3131 if ([string ]::IsNullOrWhiteSpace($Path )) {
32- throw " GitHub Actions path file must not be empty."
32+ throw " GitHub Actions path file path must not be empty."
3333 }
3434
3535 if ([string ]::IsNullOrWhiteSpace($Value )) {
36- throw " GitHub Actions path entries must not be empty."
36+ throw " GitHub Actions path entry must not be empty."
3737 }
3838
3939 $utf8NoBom = [System.Text.UTF8Encoding ]::new($false )
Original file line number Diff line number Diff line change 1919 [string []]$PrependPath
2020)
2121
22- . " $PSScriptRoot \GitHubActions.ps1"
22+ if ($env: GITHUB_ACTIONS ) {
23+ . " $PSScriptRoot \GitHubActions.ps1"
24+ }
2325
2426if ($Variables.Count -eq 0 ) {
2527 return $true
You can’t perform that action at this time.
0 commit comments