Skip to content

Restrict what's published to AppVeyor NuGet feed (BDN nightly) #2047

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

Merged
merged 1 commit into from
Jul 22, 2022

Conversation

mawosoft
Copy link
Contributor

  • Fixes cake build regression introduced by switching from the old cake script

    BenchmarkDotNet/build.cake

    Lines 151 to 153 in a936815

    Task("Pack")
    .IsDependentOn("Build")
    .WithCriteria((IsOnAppVeyorAndNotPR || string.Equals(target, "pack", StringComparison.OrdinalIgnoreCase)) && isRunningOnWindows)
  • and additionally excludes any builds triggered from commits to non-master branches.

The Cake Pack task is executed only if the build:

  • runs on AppVeyor
  • is not a PR
  • is triggered from 'master' branch
  • runs on Windows

Reason:
On AppVeyor, the packages produced by Pack are automatically uploaded as artifacts AND to the AppVeyor NuGet feed.
On GitHub and Azure Pipelines, Pack output is discarded anyway.

Fixes #1937.

- Fixes cake build regression introduced by switching from the old cake script
https://github.com/dotnet/BenchmarkDotNet/blob/a936815f2a58d9b728cfc5fe620bba17481c180c/build.cake#L151-L153
- and additionally excludes any builds triggered from commits to non-master branches.

The Cake Pack task is executed only if the build:
- runs on AppVeyor
- is not a PR
- is triggered from 'master' branch
- runs on Windows

Reason:
On AppVeyor, the packages produced by Pack are automatically uploaded as artifacts AND to the AppVeyor NuGet feed.
On GitHub and Azure Pipelines, Pack output is discarded anyway.

Fixes dotnet#1937.
Copy link
Member

@adamsitnik adamsitnik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thank you @mawosoft !

cc @AndreyAkinshin

@adamsitnik adamsitnik merged commit d6020e9 into dotnet:master Jul 22, 2022
@adamsitnik adamsitnik added this to the v0.13.2 milestone Jul 22, 2022
@mawosoft mawosoft deleted the fix-cakebuild branch July 22, 2022 09:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PR builds should not be published to BDN nightly feed
2 participants