]> git.lizzy.rs Git - rust.git/commitdiff
Add clippy_dev checks to GitHub Actions
authorflip1995 <hello@philkrones.com>
Tue, 21 Jan 2020 12:46:53 +0000 (13:46 +0100)
committerflip1995 <hello@philkrones.com>
Wed, 12 Feb 2020 08:34:25 +0000 (09:34 +0100)
.github/workflows/clippy_dev.yml [new file with mode: 0644]

diff --git a/.github/workflows/clippy_dev.yml b/.github/workflows/clippy_dev.yml
new file mode 100644 (file)
index 0000000..d054b6b
--- /dev/null
@@ -0,0 +1,44 @@
+name: Clippy Dev Test
+
+on:
+  # Only run on paths, that get checked by the clippy_dev tool
+  push:
+    paths:
+    - 'CAHNGELOG.md'
+    - 'README.md'
+    - '**.stderr'
+    - '**.rs'
+  pull_request:
+    paths:
+    - 'CAHNGELOG.md'
+    - 'README.md'
+    - '**.stderr'
+    - '**.rs'
+
+env:
+  RUST_BACKTRACE: 1
+
+jobs:
+  clippy_dev:
+    runs-on: ubuntu-latest
+
+    steps:
+    - name: rust-toolchain
+      uses: actions-rs/toolchain@v1.0.3
+      with:
+        toolchain: nightly
+        target: x86_64-unknown-linux-gnu
+        profile: minimal
+        components: rustfmt
+    - name: Checkout
+      uses: actions/checkout@v2.0.0
+
+    - name: Build
+      run: cargo build --features deny-warnings
+      working-directory: clippy_dev
+    - name: Test limit-stderr-length
+      run: cargo dev --limit-stderr-length
+    - name: Test update_lints
+      run: cargo dev update_lints --check
+    - name: Test fmt
+      run: cargo dev fmt --check