Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skip MNTRNuGet pack when skipping builds #3795

Merged
merged 2 commits into from
May 18, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 19 additions & 17 deletions build.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -398,6 +398,7 @@ Target "NBench" <| fun _ ->
//--------------------------------------------------------------------------------

Target "CreateNuget" (fun _ ->
CreateDir outputNuGet // need this to stop Azure pipelines copy stage from error-ing out
if not skipBuild.Value then
let projects =
let rawProjects = !! "src/**/*.*sproj"
Expand Down Expand Up @@ -459,26 +460,27 @@ Target "PublishMntr" (fun _ ->
)

Target "CreateMntrNuget" (fun _ ->
// uses the template file to create a temporary .nuspec file with the correct version
CopyFile "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec" "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec.template"
let commonPropsVersionPrefix = XMLRead true "./src/common.props" "" "" "//Project/PropertyGroup/VersionPrefix" |> Seq.head
let versionReplacement = List.ofSeq [ "@version@", commonPropsVersionPrefix + (if (not (versionSuffix = "")) then ("-" + versionSuffix) else "") ]
TemplateHelper.processTemplates versionReplacement [ "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec" ]
if not skipBuild.Value then
// uses the template file to create a temporary .nuspec file with the correct version
CopyFile "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec" "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec.template"
let commonPropsVersionPrefix = XMLRead true "./src/common.props" "" "" "//Project/PropertyGroup/VersionPrefix" |> Seq.head
let versionReplacement = List.ofSeq [ "@version@", commonPropsVersionPrefix + (if (not (versionSuffix = "")) then ("-" + versionSuffix) else "") ]
TemplateHelper.processTemplates versionReplacement [ "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec" ]

let executableProjects = !! "./src/**/Akka.MultiNodeTestRunner.csproj"
let executableProjects = !! "./src/**/Akka.MultiNodeTestRunner.csproj"

executableProjects |> Seq.iter (fun project ->
DotNetCli.Pack
(fun p ->
{ p with
Project = project
Configuration = configuration
AdditionalArgs = ["--include-symbols"]
VersionSuffix = versionSuffix
OutputPath = outputNuGet } )
)
executableProjects |> Seq.iter (fun project ->
DotNetCli.Pack
(fun p ->
{ p with
Project = project
Configuration = configuration
AdditionalArgs = ["--include-symbols"]
VersionSuffix = versionSuffix
OutputPath = outputNuGet } )
)

DeleteFile "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec"
DeleteFile "./src/core/Akka.MultiNodeTestRunner/Akka.MultiNodeTestRunner.nuspec"
)

Target "PublishNuget" (fun _ ->
Expand Down