Skip to content

Commit 6ab1b59

Browse files
committed
Merge branch 'main' into microbuild
2 parents 65a9b52 + 8201f77 commit 6ab1b59

2 files changed

Lines changed: 7 additions & 5 deletions

File tree

tools/GitHubActions.ps1

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff 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)

tools/Set-EnvVars.ps1

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ Param(
1919
[string[]]$PrependPath
2020
)
2121

22-
. "$PSScriptRoot\GitHubActions.ps1"
22+
if ($env:GITHUB_ACTIONS) {
23+
. "$PSScriptRoot\GitHubActions.ps1"
24+
}
2325

2426
if ($Variables.Count -eq 0) {
2527
return $true

0 commit comments

Comments
 (0)