Skip to content

Commit

Permalink
Use newest branch if we have multiple matches.
Browse files Browse the repository at this point in the history
  • Loading branch information
mnlipp committed Jun 24, 2024
1 parent e994fa1 commit 8a434d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ stages:
- "*/build"
before_script:
- echo -n $CI_REGISTRY_PASSWORD | podman login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY
- git switch $(git branch -r --contains $CI_COMMIT_SHA | sed -e 's#[^/]*/##')
- git switch $(git branch -r --sort="authordate" --contains $CI_COMMIT_SHA | head -1 | sed -e 's#[^/]*/##')
- git pull
- git reset --hard $CI_COMMIT_SHA

Expand Down

0 comments on commit 8a434d8

Please sign in to comment.