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

Suggestion: trigger a build on a pull request to have some assurance that the PR is compatible #8

Open
AndrzejProchyra opened this issue Apr 3, 2023 · 4 comments

Comments

@AndrzejProchyra
Copy link
Contributor

Maybe it's possible to run a preview build and test it somehow to get confidence that it doesn't just refuse to run... 🤔

@hjvoid
Copy link
Owner

hjvoid commented Apr 25, 2023

Great shout! What's the best way to implement this?

@AndrzejProchyra
Copy link
Contributor Author

Hmm... dunno about "best", 🙂 but there seem to be various ways to do it. I Googled a bit and I think the simplest is to make the deploy job conditional on the branch being master. We can try adding the following to the deploy job:

if: github.ref == 'refs/heads/master'

And add the additional workflow trigger:

pull_request:
    branches: [ main ]

GitHub Actions is one of those things that's so flexible that it's really hard to just get a "just tell me what to do!" answer from the docs...

@AndrzejProchyra
Copy link
Contributor Author

I'll have a go in my fork and maybe do a PR

@AndrzejProchyra
Copy link
Contributor Author

AndrzejProchyra commented Apr 25, 2023

OK, that works, but we should also make the Pages artefact upload conditional on the branch name. Is it possible to set up different environments so that you can visually inspect a PR build to see if it even runs? And are there good automated tests to check if the game starts up?

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

No branches or pull requests

2 participants