diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 35c0622..2dc28f0 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -29,7 +29,4 @@ jobs: with: packages: libgtk-3-dev libsoup-3.0-dev libjavascriptcoregtk-4.1-dev libwebkit2gtk-4.1-dev version: 1.0 - - name: Run clippy - run: cargo clippy --all --tests -- -Dwarnings - - name: Check formatting - run: cargo fmt --all --check + - run: npm run check-rs diff --git a/package.json b/package.json index d81d13b..38211a6 100644 --- a/package.json +++ b/package.json @@ -8,7 +8,8 @@ "start": "vite", "build": "vite build", "preview": "vite preview", - "check": "scripts/check", + "check": "scripts/check-js", + "check-rs": "scripts/check-rs", "format": "npx prettier '**/*.@(ts|js|svelte|json|css|html|yml)' --write", "tauri": "npx tauri" }, diff --git a/scripts/check b/scripts/check-js similarity index 100% rename from scripts/check rename to scripts/check-js diff --git a/scripts/check-rs b/scripts/check-rs new file mode 100755 index 0000000..7137fa3 --- /dev/null +++ b/scripts/check-rs @@ -0,0 +1,6 @@ +#!/bin/sh +set -e + +cargo check --manifest-path ./src-tauri/Cargo.toml +cargo clippy --manifest-path ./src-tauri/Cargo.toml -- -Dwarnings +cargo fmt --manifest-path ./src-tauri/Cargo.toml --check