SAP / jenkins-library

Jenkins shared library for Continuous Delivery pipelines.
https://www.project-piper.io
Apache License 2.0
777 stars 584 forks source link

fix(gitopsUpdateDeployment): take into account branch name when clonning #4811

Closed Googlom closed 7 months ago

Googlom commented 7 months ago

gitopsUpdateDeployment doesn't take into account branchName parameter when clonning a repo. This leads to a bug when specifying branchName other than default (main or master). In that case git clones default branch and then tries to check out to branchName (which doesn't exist in cloned repo) and then creates that branchName from default branch.

This PR fixes this bug by passing branchName into clone function

Googlom commented 7 months ago

/it-go

sonarcloud[bot] commented 7 months ago

Quality Gate Passed Quality Gate passed

Kudos, no new issues were introduced!

0 New issues
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

Googlom commented 7 months ago

/it-go