Skip to content
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

Rename CSC primary branch to follow best practices #119

Closed
peterrhysthomas opened this issue May 6, 2021 · 16 comments · Fixed by #132
Closed

Rename CSC primary branch to follow best practices #119

peterrhysthomas opened this issue May 6, 2021 · 16 comments · Fixed by #132
Assignees

Comments

@peterrhysthomas
Copy link
Contributor

CSC implementation for overall issue finos/community#114

@TLATER
Copy link
Contributor

TLATER commented May 6, 2021

Hi @mcleo-d, just a friendly reminder to figure out why I cannot be assigned ;)

@mcleo-d
Copy link
Member

mcleo-d commented May 6, 2021

Hi @TLATER - I have created the Cloud Service Certification team in FINOS and have added you as a member. That means you can now be assigned to issues - https://github.com/orgs/finos/teams/cloud-cert-participants 👍

Thanks for the reminder! 😸

@TLATER
Copy link
Contributor

TLATER commented May 11, 2021

I've tested this here: https://github.com/TLATER/master-migration-test

GitHub is quite helpful and automatically changes the PR targets, but local "main/master" branches on contributor machines do need to be updated manually. Any local "upstream" targets for non-main branches will need to be updated too, for convenient diffing.

So we'll break contributors' local repositories a little. This seems fine as long as everybody is made aware.

The actual change is easy enough, someone with sufficient repository ownership just needs to change the name of the default branch in Settings -> Branches.

Other potential bits of fallout are in CI (if any CI system runs git checkout https://github.com/finos/cloud-service-certification -b master or such), but this isn't present in our repository yet, so there should be no other problems.

@TLATER
Copy link
Contributor

TLATER commented May 11, 2021

I'll get some docs ready on how to update local branches, and ping them on the slack; we can then follow up in the next group meeting, and pull the trigger after that?

@TLATER
Copy link
Contributor

TLATER commented May 18, 2021

Here's a script that will fix branch upstreams locally; note this makes use of bash-style string manipulation, so fish users will probably need something else (zsh works fine):

Please run this after the main branch exists, not before

git for-each-ref --format='%(refname:short).%(upstream:short)' refs/heads | \
    while read entry; do
        branch="${entry%.*}"
        upstream="${entry#*.}"

        # Changes the upstream branches of anything that was
        # previously pointing to master to main
        if [ "${upstream}" = "origin/master" ]; then
            echo git branch "${branch}" --set-upstream-to "origin/main"
        elif [ "${upstream}" = "master" ]; then
            echo git branch "${branch}" --set-upstream-to "main"
        fi

        # Sets the "default" origin branch to main
        git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/main

        # Renames our local master branch to main as well
        git branch --move master main
    done

Private forks will of course need their master branches to be renamed by the respective owners.

If you have any branches that point to a private fork's master, it's probably best to just update their upstreams individually. In the future, avoid pointing to a private repositories' main branch, as it will ultimately go out of sync with upstream and therefore doesn't really serve as a good diff anyway.

@mcleo-d
Copy link
Member

mcleo-d commented May 27, 2021

@maoo has been invited to discuss in the next CSC sprint meeting on 3rd June here ...

@mcleo-d
Copy link
Member

mcleo-d commented Jun 11, 2021

Hi @TLATER (and @maoo)

I have extended CSC Sprint 2 until 17th June '21 due to team member annual leave and have added this item to the #127 agenda to discuss in relation to completion and Sprint 3.

Please find below a link to the CSC Channel in FINOS Slack where the following question was asked.
https://finos-lf.slack.com/archives/C01RNUMC2DP/p1622730250024900

Screenshot 2021-06-11 at 12 00 42

Maybe we can extend the vote and decide on the call for Sprint 3?

Cheers,

James 🚀

@TLATER
Copy link
Contributor

TLATER commented Jun 11, 2021

Yep, I think so! A lot of us were on leave that week, so the lack of feedback so far was probably expected :)

@mcleo-d mcleo-d removed the ready for review Item ready for review by the wider community label Jun 18, 2021
@mcleo-d
Copy link
Member

mcleo-d commented Jun 18, 2021

Hi @maoo 👋🏻

It was agreed during Cloud Service Certification meeting #127 that this is the top issue to resolve during Sprint 3 (https://github.com/orgs/finos/projects/1#column-14492299) and no pull requests will be raised or updated until done.

Can you work with @TLATER to update the main repo branch so @TLATER can make changes to underlying dependencies and document what other FINOS projects should do to follow?

Many thanks,

James 🚀

@mcleo-d
Copy link
Member

mcleo-d commented Jun 18, 2021

Hi @TLATER 👋🏻

Regarding the documentation for this change, it would be great if you could raise a PR adding markdown to the development-infrastructure section of the FINOS Open Developer Platform microsite ... https://github.com/finos/open-developer-platform/tree/master/docs/development-infrastructure

The development-infrastructure folder above ☝🏻 drives the development-infrastructure content found on the ODP site here https://odp.finos.org/docs/what-is-odp/. The microsite will be rebuilt when the PR is merged.

Then, we can add a reference to your documentation to the FINOS Maintainers Cheatsheet where the content of the page is found here ... https://github.com/finos/open-developer-platform/blob/master/docs/finos-maintainer-cheatsheet.mdx. This is how we scale the change ... 🏎️ 💨

When done, we can present on the FINOS All Community Call at the end of July. WDYT?

James 🚀

@TLATER
Copy link
Contributor

TLATER commented Jun 18, 2021

Yes, this sounds good, I'll get a PR up there asap :)

@TLATER
Copy link
Contributor

TLATER commented Jun 21, 2021

I think we're blocked by the above PR after all - absolutely my bad for forgetting to check for absolute links in markdown.

@mcleo-d
Copy link
Member

mcleo-d commented Jul 1, 2021

@TLATER and @maoo,

This is on hold until CSC Sprint 4 to unblock @leefaus, @J0EG and @eddie-knight on their merging and raising of pull requests ...

Related to ... #91, #84, #124, #62, #128

@mcleo-d
Copy link
Member

mcleo-d commented Jul 19, 2021

@TLATER and @maoo 👋🏻

This is to confirm this issue has been prioritised at the top of Sprint 4 that ends of 12th August.

It would be great if this item can be completed ASAP.

James.

@mcleo-d
Copy link
Member

mcleo-d commented Jul 20, 2021

@TLATER and @peterrhysthomas

The Cloud Service Certification master branch is now renamed to main! Please notify the CSC team with the following, as CSC members will have to manually update their local environments:

git branch -m master main
git fetch origin
git branch -u origin/main main
git remote set-head origin -a

@mcleo-d
Copy link
Member

mcleo-d commented Jul 20, 2021

The following PR has been raised to add the update to the repo README.md #132

@TLATER and @peterrhysthomas can you review and accept the PR above ☝🏻

Thanks!

James 🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants