-
Notifications
You must be signed in to change notification settings - Fork 27
55 lines (48 loc) · 1.25 KB
/
export.yml
File metadata and controls
55 lines (48 loc) · 1.25 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
name: "Build and Export Game"
on:
workflow_dispatch:
pull_request:
release:
types:
- published
push:
branches:
- "*"
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
jobs:
build:
name: Build for web
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v6
with:
lfs: true
- uses: endlessm/godot-export-action@v1
with:
godot_version: "4.6"
- name: Upload web artifact
uses: actions/upload-artifact@v7
with:
name: web
path: build/web
release:
name: Attach to release
needs: [build]
if: ${{ github.event_name == 'release' }}
runs-on: ubuntu-latest
steps:
- name: Download web bundle
uses: actions/download-artifact@v8
with:
name: web
path: web
- name: Attach web bundle to release
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
pushd web
zip -r "../moddable-platformer-${{ github.ref_name }}-web.zip" .
popd
gh release upload '${{ github.ref_name }}' 'moddable-platformer-${{ github.ref_name }}-web.zip' --repo '${{ github.repository }}'