Skip to content

Commit

Permalink
Fixed failure loading VstsTaskSdk #361 (#362)
Browse files Browse the repository at this point in the history
  • Loading branch information
BernieWhite authored Apr 9, 2022
1 parent 84ed37d commit 3fb8858
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 2 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ What's changed since v1.5.0:
- Configure repository to install modules from the named repository.
- General improvements:
- Expose more rule error output in CI. [#308](https://github.com/microsoft/PSRule-pipelines/issues/308)
- Bug fixes:
- Fixed failure loading VstsTaskSdk. [#361](https://github.com/microsoft/PSRule-pipelines/issues/361)

## v1.5.0

Expand Down
2 changes: 1 addition & 1 deletion tasks/ps-rule-assertV2/powershell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ async function run() {
// Import SDK
contents.push(`$rootPath = '${__dirname}';`);
contents.push(`$sdkPath = Join-Path -Path $rootPath -ChildPath 'ps_modules/VstsTaskSdk';`);
contents.push(`Import-Module $sdkPath -ArgumentList @{ NonInteractive = 'true' }`);
contents.push(`Import-Module $sdkPath -ArgumentList @{ NonInteractive = 'true' } -ErrorAction Stop`);

// Prepare parameters
contents.push(`$scriptParams = @{ Path = '${input_path}'; InputType = '${input_inputType}'; InputPath = '${input_inputPath}' };`);
Expand Down
2 changes: 1 addition & 1 deletion tasks/ps-rule-installV2/powershell.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ async function run() {
// Import SDK
contents.push(`$rootPath = '${__dirname}';`);
contents.push(`$sdkPath = Join-Path -Path $rootPath -ChildPath 'ps_modules/VstsTaskSdk';`);
contents.push(`Import-Module $sdkPath -ArgumentList @{ NonInteractive = 'true' }`);
contents.push(`Import-Module $sdkPath -ArgumentList @{ NonInteractive = 'true' } -ErrorAction Stop`);

// Prepare parameters
contents.push(`$scriptParams = @{ };`);
Expand Down
24 changes: 24 additions & 0 deletions vss-extension.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@
"path": "ps_modules/PSRule/1.11.1",
"packagePath": "/ps-rule-assert/ps-rule-assertV0/ps_modules/PSRule/1.11.1"
},
{
"path": "ps_modules/VstsTaskSdk",
"packagePath": "/ps-rule-assert/ps-rule-assertV0/ps_modules/VstsTaskSdk"
},
{
"path": "ps_modules/PowerShellGet",
"packagePath": "/ps-rule-install/ps-rule-installV0/ps_modules/PowerShellGet"
Expand All @@ -63,10 +67,18 @@
"path": "ps_modules/PackageManagement",
"packagePath": "/ps-rule-install/ps-rule-installV0/ps_modules/PackageManagement"
},
{
"path": "ps_modules/VstsTaskSdk",
"packagePath": "/ps-rule-install/ps-rule-installV0/ps_modules/VstsTaskSdk"
},
{
"path": "ps_modules/PSRule/1.11.1",
"packagePath": "/ps-rule-assert/ps-rule-assertV1/ps_modules/PSRule/1.11.1"
},
{
"path": "ps_modules/VstsTaskSdk",
"packagePath": "/ps-rule-assert/ps-rule-assertV1/ps_modules/VstsTaskSdk"
},
{
"path": "ps_modules/PowerShellGet",
"packagePath": "/ps-rule-install/ps-rule-installV1/ps_modules/PowerShellGet"
Expand All @@ -75,6 +87,10 @@
"path": "ps_modules/PackageManagement",
"packagePath": "/ps-rule-install/ps-rule-installV1/ps_modules/PackageManagement"
},
{
"path": "ps_modules/VstsTaskSdk",
"packagePath": "/ps-rule-install/ps-rule-installV1/ps_modules/VstsTaskSdk"
},
{
"path": "modules.json",
"packagePath": "/ps-rule-assert/ps-rule-assertV2/modules.json"
Expand All @@ -83,13 +99,21 @@
"path": "ps_modules/PSRule/2.0.0",
"packagePath": "/ps-rule-assert/ps-rule-assertV2/ps_modules/PSRule/2.0.0"
},
{
"path": "ps_modules/VstsTaskSdk",
"packagePath": "/ps-rule-assert/ps-rule-assertV2/ps_modules/VstsTaskSdk"
},
{
"path": "ps_modules/PowerShellGet",
"packagePath": "/ps-rule-install/ps-rule-installV2/ps_modules/PowerShellGet"
},
{
"path": "ps_modules/PackageManagement",
"packagePath": "/ps-rule-install/ps-rule-installV2/ps_modules/PackageManagement"
},
{
"path": "ps_modules/VstsTaskSdk",
"packagePath": "/ps-rule-install/ps-rule-installV2/ps_modules/VstsTaskSdk"
}
],
"contributions": [
Expand Down

0 comments on commit 3fb8858

Please sign in to comment.