aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.github/workflows/pygbag.yml21
-rw-r--r--main.py18
2 files changed, 39 insertions, 0 deletions
diff --git a/.github/workflows/pygbag.yml b/.github/workflows/pygbag.yml
new file mode 100644
index 0000000..3f6f9c8
--- /dev/null
+++ b/.github/workflows/pygbag.yml
@@ -0,0 +1,21 @@
+
+name: pygbag_build
+on: [workflow_dispatch]
+
+
+jobs:
+ build-pygbag:
+ name: Build for Emscripten pygbag runtime
+ runs-on: ubuntu-latest
+
+ steps:
+ - uses: actions/checkout@v2
+ - name: Checkout
+ run: |
+ python -m pip install pygbag
+ python -m pygbag --build $GITHUB_WORKSPACE/main.py
+ - name : "Upload to GitHub pages branch gh-pages"
+ uses: JamesIves/github-pages-deploy-action@4.1.7
+ with:
+ branch: gh-pages
+ folder: build/web
diff --git a/main.py b/main.py
new file mode 100644
index 0000000..d82800a
--- /dev/null
+++ b/main.py
@@ -0,0 +1,18 @@
+import pygame
+
+import asyncio
+
+import pygame
+
+from Steuerung import Steuerung
+
+
+async def main():
+ pygame.init()
+ steuerung = Steuerung(start_loop=False)
+ await steuerung.loop()
+ pygame.quit()
+
+
+if __name__ == "__main__":
+ asyncio.run(main())