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

chore: only push to AppHub if build was created #3392

Merged
merged 4 commits into from
Nov 7, 2024

Conversation

jenniferarnesen
Copy link
Collaborator

@jenniferarnesen jenniferarnesen commented Nov 4, 2024

There are 2 main improvements to the workflow to help solve all the failing builds:

  • Instead of complex if statements in the gh workflow file (they aren't even working anyway!), use commit_analyzer config to prevent release for our [skip release] and [skip ci] PRs.
  • publishing to AppHub fails if there is no build file, which there won't be in the case of chores and [skip release]. So add an if statement that checks for an env var. The env var gets set to true if there is a build.

Here's some workflow outputs that demonstrate the above changes in a test repo:

build_exists has been set to true and Publish AppHub runs: https://github.com/jenniferarnesen/dhis2-ci-demo/actions/runs/11667460947/job/32484827377

Skip publishing to App hub when [skip release] (even when the commit was a fix or feature): https://github.com/jenniferarnesen/dhis2-ci-demo/actions/runs/11681915720/job/32527955692#step:5:55

@dhis2-bot
Copy link
Contributor

dhis2-bot commented Nov 4, 2024

🚀 Deployed on https://pr-3392.maps.netlify.dhis2.org

@dhis2-bot dhis2-bot temporarily deployed to netlify November 4, 2024 16:08 Inactive
@dhis2-bot dhis2-bot temporarily deployed to netlify November 5, 2024 14:44 Inactive
@jenniferarnesen jenniferarnesen merged commit 226ac3d into master Nov 7, 2024
18 checks passed
@jenniferarnesen jenniferarnesen deleted the chore/release-workflow-only-on-release branch November 7, 2024 14:48
@dhis2-bot
Copy link
Contributor

🎉 This PR is included in version 100.7.5 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

3 participants