-
Notifications
You must be signed in to change notification settings - Fork 273
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
automatically generate version suffixes #2709
Changes from 4 commits
1bf5c3f
d16f78a
a5f6806
a1e0c4f
e7ba68b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,17 @@ pool: | |
demands: | ||
- ImageOverride -equals MMS2022TLS | ||
|
||
variables: | ||
|
||
- name: PackageSuffix | ||
# if source branch is not `dev` then we're generating a release based on a feature branch | ||
# In that case, we populate the environment variable "PackageSuffix" accordingly | ||
${{ if ne(variables['Build.SourceBranchName'], 'dev') }}: | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here, can check Release build can be manual queue and dev branch. And does this build def get ran post merge? In which case that would be a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Today, this pipeline only runs when manually triggered, so it does not run automatically post-merge. The nightly pipeline does run post-merge, but that's a different In this case, since this pipeline is always manual - do you think still think it makes sense to check There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If we you do the build reason calculation, that is a step towards getting rid of the separate nightly pipeline and using this one for that as well. Also, this is used for PRs as well is it not? |
||
value: 'pr.$(Build.BuildNumber)' # the "pr" section is to denote this code is a candidate to be PR'ed | ||
${{ else }}: | ||
value: '' | ||
|
||
|
||
steps: | ||
|
||
# Configure all the .NET SDK versions we need | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest checking
$(Build.Reason)
instead of source branch:https://learn.microsoft.com/en-us/azure/devops/pipelines/build/variables?view=azure-devops&tabs=yaml
Can differentiate PR and CI this way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll look into
$(Build.Reason)
, good idea.Though I just realized I made a mistake here - The
nightly
build should probably only build fromdev
anyways. So I should change to logic here so this is always aci
build.