Skip to content

Commit 5044955

Browse files
committed
Don't trigger PR workflows on drafts
1 parent 4815ed7 commit 5044955

File tree

9 files changed

+21
-0
lines changed

9 files changed

+21
-0
lines changed

.github/workflows/build-android.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ jobs:
3838
# Build Stride Runtime for Android
3939
#
4040
Android-Runtime:
41+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
4142
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }})
4243
runs-on: windows-latest
4344
steps:

.github/workflows/build-assembly-processor.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ jobs:
3434
# Build Assembly Processor
3535
#
3636
Assembly-Processor:
37+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
3738
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }})
3839
runs-on: windows-latest
3940
steps:

.github/workflows/build-ios.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ jobs:
3838
# Build Stride Runtime for iOS
3939
#
4040
iOS-Runtime:
41+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
4142
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }})
4243
runs-on: windows-latest
4344
steps:

.github/workflows/build-linux-runtime.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ jobs:
4848
# Build Stride Runtime for Linux
4949
#
5050
Linux-Runtime:
51+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
5152
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }}, ${{ github.event.inputs.graphics-api || inputs.graphics-api || 'OpenGL' }})
5253
runs-on: windows-latest
5354
steps:

.github/workflows/build-vs-package.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ jobs:
3333
# Build Visual Studio Package
3434
#
3535
VS-Package:
36+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
3637
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }})
3738
runs-on: windows-latest
3839
steps:

.github/workflows/build-windows-full.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ jobs:
3333
# Build Stride for Windows
3434
#
3535
Windows:
36+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
3637
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }})
3738
runs-on: windows-latest
3839
steps:

.github/workflows/build-windows-runtime.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ jobs:
5151
# Build Stride Runtime for Windows
5252
#
5353
Windows-Runtime:
54+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
5455
name: Build (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }}, ${{ github.event.inputs.graphics-api || inputs.graphics-api || 'Direct3D11' }})
5556
runs-on: windows-latest
5657
steps:

.github/workflows/test-linux.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ jobs:
3131
# Test Stride on Linux
3232
#
3333
Linux-Tests:
34+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
3435
name: Test (${{ github.event.inputs.build-type || inputs.build-type }}, ${{ github.event.inputs.test-category || inputs.test-category }})
3536
runs-on: ubuntu-latest
3637
steps:

.github/workflows/test-windows.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,18 @@
11
name: Test Windows
22

33
on:
4+
pull_request:
5+
paths:
6+
- '.github/workflows/test-windows.yml'
7+
- 'build/Stride.Tests.*.slnf'
8+
- 'deps/**'
9+
- 'sources/**'
10+
- '!**/.all-contributorsrc'
11+
- '!**/.editorconfig'
12+
- '!**/.gitignore'
13+
- '!**/*.md'
14+
- '!crowdin.yml'
15+
types: [opened, synchronize, reopened, ready_for_review]
416
workflow_dispatch:
517
inputs:
618
build-type:
@@ -32,6 +44,7 @@ jobs:
3244
# Test Stride on Windows
3345
#
3446
Windows-Tests:
47+
if: ${{ github.event_name == 'workflow_dispatch' || github.event_name == 'workflow_call' || github.event.pull_request.draft == false }}
3548
name: Test (${{ github.event.inputs.build-type || inputs.build-type || 'Debug' }}, ${{ github.event.inputs.test-category || inputs.test-category || 'Simple' }})
3649
runs-on: windows-latest
3750
steps:

0 commit comments

Comments
 (0)