Skip to content

Commit c1d1c3f

Browse files
authored
Material Site/Docs/Demos have to be manually deployed to material.slint.dev (#9499)
This changes the behaviour so PR's still deploy, but will end up at preview URL's. However the merge to master no longer deploys a production site. Instead the production site can only be deployed manually via the github site.
1 parent 162ce67 commit c1d1c3f

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

.github/workflows/material.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,23 @@ name: Build, test and deploy docs
55

66
on:
77
workflow_dispatch:
8+
inputs:
9+
publish:
10+
type: boolean
11+
description: "Publish master to Cloudflare Pages"
12+
default: false
13+
required: false
14+
pull_request:
15+
push:
16+
branches-ignore:
17+
- master
818
workflow_call:
19+
inputs:
20+
publish:
21+
type: boolean
22+
required: false
23+
default: false
24+
description: "Tick the box to publish master to material.slint.dev"
925
secrets:
1026
CLOUDFLARE_API_TOKEN:
1127
required: true
@@ -52,6 +68,7 @@ jobs:
5268
run: cargo test -p material-gallery
5369

5470
deploy:
71+
if: ${{ (github.event_name == 'workflow_dispatch' && github.event.inputs.publish == 'true') || (github.event_name == 'workflow_call' && inputs.publish == true) || github.ref != 'refs/heads/master' }}
5572
runs-on: ubuntu-latest
5673
needs: [wasm_demo, apk_demo]
5774
permissions:

0 commit comments

Comments
 (0)