[FOLIO-3172] Amend Jenkins Sonar config to use main git branch rather than master branch Created: 25/May/21  Updated: 03/Jun/21

Status: Open
Project: FOLIO
Components: None
Affects versions: None
Fix versions: None

Type: Bug Priority: TBD
Reporter: Julian Ladisch Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original estimate: Not Specified

Issue links:
Cloners
clones FOLIO-2851 Amend Jenkins Sonar config to use def... Open
Relates
relates to FOLIO-2811 Rename default branch of all existing... Open
relates to FOLIO-2843 Create remote storage repository and... Closed
Sprint:
Development Team: FOLIO DevOps

 Description   

FOLIO-2811 Open is going to rename "master" to "main" in each FOLIO repo. GitHub automatically redirects old links to the "master" branch to access the "main" branch: https://github.com/github/renaming#whats-already-changed

However, newly created repositories that never had a "master" branch require all scripts to access the "main" branch.

Example:

git fetch --no-tags \
  https://github.com/folio-org/ui-remote-storage.git \
  +refs/heads/master:refs/remotes/origin/master
fatal: couldn't find remote ref refs/heads/master

Task:

Replace "master" to "main" in scripts.

Example:

git fetch --no-tags \
  https://github.com/folio-org/ui-remote-storage.git \
  +refs/heads/main:refs/remotes/origin/main

Note:

This tasks hard-codes "main". This is a simple search-and-replace task.

In contrast FOLIO-2851 Open proposes to detect the default branch which is much more work – this is not worth the effort because all FOLIO repositories are going to use "main" as the default branch ( FOLIO-2811 Open ). FOLIO will not support different default branch names.

 



 Comments   
Comment by David Crossley [ 26/May/21 ]

The tickets FOLIO-2851 Open FOLIO-3172 Open relate to just one situation.

There are many situations of configuration and scripts in all of FOLIO infrastructure which explicitly refer to "master". Some will not be a simple replace.

At FOLIO-2858 In Progress the FOLIO DevOps team will be handling the transition.

Generated at Thu Feb 08 23:26:09 UTC 2024 using Jira 1001.0.0-SNAPSHOT#100246-sha1:7a5c50119eb0633d306e14180817ddef5e80c75d.