-
Notifications
You must be signed in to change notification settings - Fork 274
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added publish script for PowerShell SDK (#975)
* simple yampl to create pipeline * Add additional steps into pipeline to publish nuget feed * Upgrade net framework version * Revert csproj changes * Specify msbuild version for old netframework support * Add arch argument to msbuild installation * Bump package version * Use nuspec version directly * Fix downloadFileAsync * rm committed minimatch dll * Move publish steps to job + temp disable it * Move version to package back. Fix encoding * Add publish script * Update tags * update company metadata * Update to publish to powershell gallery --------- Co-authored-by: Konstantin Tyukalov <v-ktyukalov@microsoft.com> Co-authored-by: Konstantin Tyukalov <52399739+KonstantinTyukalov@users.noreply.github.com>
- Loading branch information
1 parent
5fb0f50
commit f952803
Showing
8 changed files
with
58 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
jobs: | ||
- job: Publish | ||
displayName: Publish SDK to PowerShell gallery | ||
pool: | ||
vmImage: windows-2022 | ||
steps: | ||
- powershell: | | ||
Install-Module -Name Microsoft.PowerShell.PSResourceGet -Verbose | ||
displayName: Install new publish cmdlets | ||
- powershell: | | ||
$publishOptions = @{ | ||
Path = './VstsTaskSdk' | ||
ApiKey = $env:API_KEY | ||
Repository = 'PSGallery' | ||
Verbose = $true | ||
} | ||
Publish-PSResource @publishOptions | ||
displayName: Publish to gallery | ||
workingDirectory: powershell/_build | ||
env: | ||
API_KEY: $(PSGalleryApiKey) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
param( | ||
[Parameter(Mandatory = $true)] | ||
[string]$ApiKey | ||
) | ||
|
||
# Install newest version of powershell management api | ||
Install-Module -Name Microsoft.PowerShell.PSResourceGet | ||
|
||
$makePath = Join-Path $PSScriptRoot 'make.js' | ||
& node $makePath build | ||
|
||
$buildPath = Join-Path $PSScriptRoot '_build' | ||
$moduleBuildPath = Join-Path $buildPath "VstsTaskSdk" | ||
|
||
$publishOptions = @{ | ||
Path = $moduleBuildPath | ||
ApiKey = $ApiKey | ||
Repository = 'PSGallery' | ||
Verbose = $true | ||
} | ||
Publish-PSResource @publishOptions |