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

GitHub pages support #23

Closed
XBagon opened this issue Mar 5, 2022 · 2 comments
Closed

GitHub pages support #23

XBagon opened this issue Mar 5, 2022 · 2 comments

Comments

@XBagon
Copy link

XBagon commented Mar 5, 2022

Are you interested in supporting GitHub pages for WASM builds?
I wanted to make my game's releases very easy to play.
For the moment I just added

      - name: Deploy to GitHub Pages
        uses: JamesIves/github-pages-deploy-action@v4.2.5
        with:
          branch: gh-pages
          folder: wasm
          clean-exclude: index.html

as an additional step of the release-wasm job.

In the future extending this feature to support multiple (all available) release and not just the most recent on could be very interesting.

@NiklasEi
Copy link
Owner

Nice idea!
I ran into a few issues with the web build setup when I tried this in the release workflow. When running on GH pages, the assets are served under a subpath (your repo name). But, rewriting the asset paths to be relative sadly breaks the normal development workflow with trunk serve.

I think a good way of supporting this would be to add a workflow that can be manually triggered and only does the deploy. The build in that workflow can then use relative links for the assets.

@NiklasEi
Copy link
Owner

Got it working: https://niklasei.github.io/bevy_game_template/
Thank you for the idea 🙂

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