Skip to content

Update branch name extraction for tag builds#608

Merged
oliverholworthy merged 2 commits intoNVIDIA-Merlin:mainfrom
oliverholworthy:fix-tag-build-branch-name
Feb 3, 2023
Merged

Update branch name extraction for tag builds#608
oliverholworthy merged 2 commits intoNVIDIA-Merlin:mainfrom
oliverholworthy:fix-tag-build-branch-name

Conversation

@oliverholworthy
Copy link
Copy Markdown
Contributor

  • Updates branch name logic for tag builds to handle leading whitespace and multiple branch names
    • git branch -r --contains v0.1.16, for example, returns origin/release-22.12. The subsequent line in our workflow failed to remove the prefix origin/ because if doesn't currently handle this whitespace.
      • using --format "%(refname:short)" to ensure we only get the branch name and not leading whitespace
    • another issue is that this tag was pointing at multiple branches, and the main branch was selected.
      • using --list '*release*' to ensure we select the release branch name. There is still an edge case where we could have the tag pointing at multiple release branches, but that seem less likely to happen.
  • The package publish failed on the last release due to the issues described above.

@oliverholworthy oliverholworthy added this to the Merlin 22.12 milestone Feb 3, 2023
@oliverholworthy oliverholworthy self-assigned this Feb 3, 2023
@github-actions
Copy link
Copy Markdown

github-actions bot commented Feb 3, 2023

@oliverholworthy oliverholworthy merged commit 84da77a into NVIDIA-Merlin:main Feb 3, 2023
oliverholworthy added a commit that referenced this pull request Feb 3, 2023
* Remove leading whitespace from branch name in workflow for tag build

* Filter branches and specify format when using git branch in workflow
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants