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
Adding a build and attach to release workflow (upon release publish). #2891
Conversation
Kudos, SonarCloud Quality Gate passed! |
Do you want to test this code? Here you have an automated build: |
Hi! I only wanted to know how different is your publish workflow, because I don't see too much difference with the other one workflow we have. |
The issue is creating artefacts and attaching when a release is in draft is that commits can be added to 'master' (before publishing), invalidating the artefacts. The artefacts potentially need replacing once published. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, understood. I prefer to have the builds before publishing and not after, but you make the release, so how you prefer and is easy to you. Only two comments.
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: Code Checkout | ||
uses: actions/checkout@v2 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we continue with the automatic execution, maybe we can, to be sure that we download what we want, specify the tag to be sure that the checkout is the correct one?
I've seen that this action has a version 3. Maybe is good too start to use the latest version. It seems the version 3 is in develop, not released, so ignore this...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it not automatically the commit that triggered the run of the job?
EDIT: Confirmed it is the commit that was tagged to trigger the run.
|
||
on: | ||
release: | ||
types: [published] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only a question, maybe is better to add a manual workflow to attach the build artifacts before the publishing? The difference is not too big, but now, the user subscribed receives the notification of a new version, and the artifacts are not available. Is not too much time, 5 minutes more or less if the build goes well (there is a possibility that it has some kind of problem).
And the Android version must be generated (and attached I suppose) out of this flow, so the user will see the Android version but nothing more.
Not a big problem, only wanted to notice it.
AUTOMERGE: (FAIL)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok. If this is the way you like to work, is ok to me.
Another question: if we launch the "earlier" release flow manually, is this flow released too? If true, then maybe remove the earlier one, it has no sense that the manual one create the artifacts, and this other replace them (or worst, duplicate them).
Good question. I would hope that it would replace them - or error. I will test that at some point and let you know. |
Simple workflow to attach the assets once a release is published.