From e6f782b4f4ce585278466ca2160205924d30937f Mon Sep 17 00:00:00 2001 From: Chet Husk Date: Wed, 19 Feb 2020 21:49:26 -0600 Subject: [PATCH] use dotnet push instead of paket push to sidestep pushing issues --- fcs/build.fsx | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/fcs/build.fsx b/fcs/build.fsx index aba0c0fdc9..44fd06cb0f 100644 --- a/fcs/build.fsx +++ b/fcs/build.fsx @@ -96,12 +96,19 @@ Target.create "GenerateDocsJa" (fun _ -> runDotnet "docsrc/tools" "fake" "run generate.ja.fsx" ) +open Fake.IO.Globbing.Operators + Target.create "PublishNuGet" (fun _ -> - let apikey = Environment.environVarOrDefault "nuget-apikey" (UserInput.getUserPassword "Nuget API Key: ") - Paket.push (fun p -> - { p with - ApiKey = apikey - WorkingDir = releaseDir }) + let apikey = lazy(Environment.environVarOrDefault "nuget-apikey" (UserInput.getUserPassword "Nuget API Key: ")) + !! (sprintf "%s/*.%s.nupkg" releaseDir release.NugetVersion) + |> Seq.iter (fun nupkg -> + DotNet.nugetPush (fun p -> { + p with + PushParams = { p.PushParams with + ApiKey = Some apikey.Value + Source = Some "https://api.nuget.org/v3/index.json" } + }) nupkg + ) ) // --------------------------------------------------------------------------------------