From a38306b69afcc7fa2fdcf235a8e33f08d722d102 Mon Sep 17 00:00:00 2001 From: pawurb Date: Fri, 29 Dec 2023 17:51:59 +0100 Subject: [PATCH] Add lint CI --- .github/workflows/ci.yml | 3 +++ src/lib.rs | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8642096..eb0d3a1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,6 +28,9 @@ jobs: uses: actions-rs/cargo@v1 with: command: check + - name: lint + with: + command: cargo clippy - name: Test env: DATABASE_URL: postgresql://postgres:secret@localhost:5432/rust_pg_extras diff --git a/src/lib.rs b/src/lib.rs index e2ebed7..c100539 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -233,7 +233,6 @@ pub fn db_settings() -> Vec { } fn read_file(filename: &str) -> String { - fs::read_to_string(format!("src/queries/{}.sql", filename)) .unwrap_or_else(|_| panic!("Error reading the '{}' file", filename)) }