Skip to content

Commit 4cbb0d2

Browse files
authored
Update CI
1 parent 1f90d63 commit 4cbb0d2

File tree

1 file changed

+11
-10
lines changed

1 file changed

+11
-10
lines changed

.github/workflows/main.yml

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: Build example
22

33
on:
44
workflow_dispatch:
5+
pull_request:
56
push:
67
branches:
78
- main
@@ -11,37 +12,37 @@ jobs:
1112
runs-on: ubuntu-latest
1213
steps:
1314
- name: Checkout 🛎️
14-
uses: actions/checkout@v3
15+
uses: actions/checkout@v4
1516

1617
- name: Install Java ♨️
17-
uses: actions/setup-java@v3
18+
uses: actions/setup-java@v4
1819
with:
1920
distribution: "temurin"
20-
java-version: "17"
21+
java-version: "25"
2122

2223
- name: Build 🔧
2324
env:
2425
DEFOLD_BOB_SHA1: ${{ vars.DEFOLD_BOB_SHA1 }}
2526
run: |
2627
lsb_release -a
2728
28-
mkdir -p build/bundle
29+
mkdir -p bundle
2930
3031
# Download the latest bob.jar
3132
BOB_SHA1=${DEFOLD_BOB_SHA1:-$(curl -s 'https://d.defold.com/stable/info.json' | jq -r .sha1)}
32-
BOB_LOCAL_SHA1=$((java -jar build/bundle/bob.jar --version | cut -d' ' -f6) || true)
33-
if [ "${BOB_LOCAL_SHA1}" != "${BOB_SHA1}" ]; then wget --progress=dot:mega -O build/bundle/bob.jar "https://d.defold.com/archive/${BOB_SHA1}/bob/bob.jar"; fi
34-
java -jar build/bundle/bob.jar --version
33+
BOB_LOCAL_SHA1=$((java -jar bundle/bob.jar --version | cut -d' ' -f6) || true)
34+
if [ "${BOB_LOCAL_SHA1}" != "${BOB_SHA1}" ]; then wget --progress=dot:mega -O bundle/bob.jar "https://d.defold.com/archive/${BOB_SHA1}/bob/bob.jar"; fi
35+
java -jar bundle/bob.jar --version
3536
3637
# Build the project
37-
java -jar build/bundle/bob.jar --email a@b.com --auth 123 --texture-compression true --bundle-output build/bundle/js-web --platform js-web --architectures wasm-web --archive --variant debug resolve build bundle
38+
java -jar bundle/bob.jar --email a@b.com --auth 123 --texture-compression true --bundle-output bundle/js-web --platform js-web --architectures wasm-web --archive --variant debug resolve build bundle
3839
3940
# Move to the public directory
40-
mv build/bundle/js-web/* build/bundle/public
41+
mv bundle/js-web/* bundle/public
4142
4243
- name: Deploy to Pages 🚀
4344
uses: JamesIves/github-pages-deploy-action@v4
4445
with:
4546
branch: gh-pages
46-
folder: build/bundle/public
47+
folder: bundle/public
4748
if: github.ref == 'refs/heads/main'

0 commit comments

Comments
 (0)