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

POC: Use reusable workflow #3

Closed
wants to merge 1 commit into from
Closed

POC: Use reusable workflow #3

wants to merge 1 commit into from

Conversation

xzfc
Copy link
Contributor

@xzfc xzfc commented Apr 19, 2022

@denis-tingaikin
Copy link
Member

@edwarnicke This apporoach is looking promising to me. I guess we can simplify many things with using resusable worflows. Do you mind if we go this apporoach?

echo "attempt $attempt"
git fetch -p origin
base=$release
git show-ref --quiet refs/remotes/origin/$base || base=main
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note: base=main is not expected for release.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the $release branch doesn't exist, we start it from the main branch. Or should we use a specific starting commit?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we should stop release if we don't have release branch

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a branch in the dependent repository (not in the current one, which is running on the CI). Currently, branches in dependent repositories are created automatically from the main branch.

Details: our current release.yaml uses the actions/checkout action to fetch the dependent repository. According to actions/checkout doc, the default (i.e. main) branch is used. Then our release.yaml creates a release branch, dropping an already existing branch (since the force push -f flag being used).


In short, the current logic of update-dependent-repositories job:
Create a release branch starting from the main branch. Override it if it already exists (hence the conflict described in the issue).

Logic In this PR:
Create a release branch if it doesn't exist. Otherwise, append a commit to an existing release branch.

@xzfc xzfc closed this by deleting the head repository May 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants