提交 9b8160f5 编写于 作者: J Jared Parsons 提交者: GitHub

Merge pull request #12401 from jaredpar/apikey

Use a proper API key
......@@ -5,6 +5,7 @@
<ProjectDir>$(MSBuildThisFileDirectory)..\..\..\</ProjectDir>
<BranchName Condition="'$(BranchName)' == ''">$(BUILD_SOURCEBRANCH)</BranchName>
<BinariesPath>$(ProjectDir)Binaries\$(Configuration)</BinariesPath>
<RoslynMyGetApiKey Condition="'$(RoslynMyGetApiKey)' == ''">"no key"</RoslynMyGetApiKey>
</PropertyGroup>
<!-- Non-official builds / local testing have different defaults -->
......@@ -38,7 +39,7 @@
<Exec Command="powershell -noprofile -executionPolicy ByPass -file $(MSBuildThisFileDirectory)stop-compiler-server.ps1" />
<Exec Command="powershell -noprofile -executionPolicy ByPass -file $(MSBuildThisFileDirectory)publish-assets.ps1 -binariesPath &quot;$(BinariesPath)&quot; -branchName $(BranchName) $(PublishAssetsArgs)" />
<Exec Command="powershell -noprofile -executionPolicy ByPass -file $(MSBuildThisFileDirectory)publish-assets.ps1 -binariesPath &quot;$(BinariesPath)&quot; -branchName $(BranchName) -apiKey $(RoslynMyGetApiKey) $(PublishAssetsArgs)" />
</Target>
</Project>
......
......@@ -19,8 +19,9 @@ Whether or not to just test this script vs. actually publish
#>
Param(
[string]$binariesPath,
[string]$branchName,
[string]$binariesPath = $null,
[string]$branchName = $null,
[string]$apiKey = $null,
[switch]$test
)
......@@ -74,11 +75,6 @@ try
$nugetPath = Join-Path $binariesPath "NuGet\PerBuildPreRelease"
[xml]$packages = Get-Content "$nugetPath\myget_org-packages.config"
$apiKey = $null;
if (-not test)
{
$apiKey = (Get-Content "\\mlangfs1\public\RoslynNuGetInfrastructure\mygetApiKey-dotnet.txt").Trim()
}
$sourceUrl = ("https://dotnet.myget.org/F/roslyn-{0}-nightly/api/v2/package" -f $branchName)
......@@ -109,7 +105,6 @@ try
$vsixPath = $binariesPath
[xml]$extensions = Get-Content "$vsixPath\myget_org-extensions.config"
$apiKey = (Get-Content "\\mlangfs1\public\RoslynNuGetInfrastructure\mygetApiKey-dotnet.txt").Trim()
pushd $vsixPath
foreach ($extension in $extensions.extensions.extension)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册