Skip to content

Commit 492db16

Browse files
authored
fix(ci): do not run CI if PR is marked as draft (#544)
1 parent a1625a9 commit 492db16

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

.github/workflows/ci.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@ name: CI
22

33
on:
44
pull_request:
5+
types:
6+
- opened
7+
- reopened
8+
- synchronize
9+
- ready_for_review
510
push:
611
branches:
712
- main
@@ -22,6 +27,7 @@ env:
2227

2328
jobs:
2429
cargo-fmt:
30+
if: github.event.pull_request.draft == false
2531
name: 'fmt'
2632
runs-on: ubuntu-latest
2733
steps:
@@ -33,6 +39,7 @@ jobs:
3339
- run: deno run --allow-write --allow-read --allow-run --allow-net ./scripts/format.js --check
3440

3541
cargo-clippy:
42+
if: github.event.pull_request.draft == false
3643
name: 'cargo clippy'
3744
runs-on: ubuntu-latest
3845
steps:
@@ -46,6 +53,7 @@ jobs:
4653
- run: ./scripts/clippy.sh
4754

4855
cargo-test:
56+
if: github.event.pull_request.draft == false
4957
name: 'cargo test'
5058
runs-on: ubuntu-latest
5159
steps:

rust-toolchain.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
[toolchain]
22
channel = "1.82.0"
3+
components = ["rustfmt", "clippy"]

0 commit comments

Comments
 (0)