diff --git a/tools/packaging/packaging.psd1 b/tools/packaging/packaging.psd1 index b72c14b80f1..b71b7e79d13 100644 --- a/tools/packaging/packaging.psd1 +++ b/tools/packaging/packaging.psd1 @@ -18,7 +18,6 @@ 'New-ILNugetPackageFromSource' 'New-PSBuildZip' 'New-PSSignedBuildZip' - 'Publish-NugetToMyGet' 'Start-PSPackage' 'Test-PackageManifest' 'Update-PSSignedBuildFolder' diff --git a/tools/packaging/packaging.psm1 b/tools/packaging/packaging.psm1 index a551a483c8d..082f917f63c 100644 --- a/tools/packaging/packaging.psm1 +++ b/tools/packaging/packaging.psm1 @@ -3559,42 +3559,6 @@ function New-NugetPackage Pop-Location } -<# -.SYNOPSIS -Publish the specified Nuget Package to MyGet feed. - -.DESCRIPTION -The specified nuget package is published to the powershell.myget.org/powershell-core feed. - -.PARAMETER PackagePath -Path to the NuGet Package. - -.PARAMETER ApiKey -API key for powershell.myget.org -#> -function Publish-NugetToMyGet -{ - param( - [Parameter(Mandatory = $true)] - [string] $PackagePath, - - [Parameter(Mandatory = $true)] - [string] $ApiKey - ) - - $nuget = Get-Command -Type Application nuget -ErrorAction SilentlyContinue - - if ($null -eq $nuget) - { - throw 'nuget application is not available in PATH' - } - - Get-ChildItem $PackagePath | ForEach-Object { - Write-Log "Pushing $_ to PowerShell Myget" - Start-NativeExecution { nuget push $_.FullName -Source 'https://powershell.myget.org/F/powershell-core/api/v2/package' -ApiKey $ApiKey } > $null - } -} - function New-SubFolder { [CmdletBinding(SupportsShouldProcess=$true)]