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

ci: finalize github release action #263

Merged
merged 3 commits into from
Jul 8, 2024
Merged

Conversation

DaniBodor
Copy link
Member

@DaniBodor DaniBodor commented Jul 5, 2024

  • fix branch names to main and develop instead of test_protected_XXX
  • use built-in branch reading system for GitHub actions (see here)
    • this is mostly more convenient than the explicit one I wrote
      • because the built-in one cannot be hidden, so would otherwise appear but have no function
      • because the built-in one uses a drop-down menu (with search functionality) of existing branches rather than a string input for the one I wrote
    • the downside is: the default cannot be changed to anything other than main, which should never actually be the release branch (the workflow will fail if main is set).

NB: I am also a bit confused now whether this PR should go to main or develop. I think main, so that the action can immediately be used as intended.

@DaniBodor DaniBodor marked this pull request as ready for review July 5, 2024 14:09
@DaniBodor DaniBodor requested a review from psomhorst July 5, 2024 14:10
Copy link
Contributor

@psomhorst psomhorst left a comment

Choose a reason for hiding this comment

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

Seems great!

You merged the previous PR #242 into main, so this should as well. This file has to exist in main before it becomes available anyway.
However, you can only use it from a branch where it already exists (see attached screenshot). So we should merge main into develop after this PR. Then, we can use it from develop.

Screenshot 2024-07-05 at 16 40 07

Isn't it possible to limit the working of workflow_dispath by adding a branch setting, just as with on: push:?

Edit: never mind, this of course won't work with branches you don't know the name of yet (e.g. hot fix branches).

Documentatie over hoe je master kan uitsluiten?

on:
workflow_dispatch:

on:
push:
branches:
- main

Copy link
Contributor

@psomhorst psomhorst left a comment

Choose a reason for hiding this comment

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

Should the action default to develop if you select main? This could lead to unexpected behaviour and unintentional releases.

Edit: sorry, I'm a bit indecisive, apparently.

@DaniBodor
Copy link
Member Author

DaniBodor commented Jul 5, 2024

It's easy enough to make the action fail if main is selected, that is no problem.
The annoying thing is that it's not possible to set the default for "Use workflow from" to anything other than main. So the question is: do we prefer

  1. a smoother user experience (i.e. re-default it to develop): e039e69
  2. decrease the probability of unexpected behavior (i.e. fail if main is selected): c72cf34

Also, don't forget that there is already a manual quality control step built in, by creating a draft-release, which actively needs to be converted to an actual release.

EDIT: we decided to go with option 2!

@DaniBodor DaniBodor force-pushed the 239_streamlined_release_dbodor branch from 424f3bd to b879d7f Compare July 8, 2024 08:20
@DaniBodor DaniBodor force-pushed the 239_streamlined_release_dbodor branch from b879d7f to c72cf34 Compare July 8, 2024 08:27
@DaniBodor DaniBodor force-pushed the 239_streamlined_release_dbodor branch from c72cf34 to b0b1ed4 Compare July 8, 2024 13:07
@DaniBodor DaniBodor merged commit 0fe1808 into main Jul 8, 2024
6 checks passed
@DaniBodor DaniBodor deleted the 239_streamlined_release_dbodor branch July 8, 2024 13:10
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