From aef0aea973d17935bc88605741a36bec4f036600 Mon Sep 17 00:00:00 2001 From: elipeter Date: Mon, 16 Jun 2025 23:54:18 +0200 Subject: [PATCH] - Rename `index.rs` to `database.rs` for clarity in purpose - Update references in `scan.rs` to the renamed module - Add `cargo clippy` step to CI for linting --- .github/workflows/rust.yml | 2 ++ src/commands/scan.rs | 2 +- src/{index.rs => database.rs} | 0 src/main.rs | 2 +- 4 files changed, 4 insertions(+), 2 deletions(-) rename src/{index.rs => database.rs} (100%) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 000bb2c4..6a095610 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -18,5 +18,7 @@ jobs: - uses: actions/checkout@v4 - name: Build run: cargo build --verbose + - name: Run linter + run: cargo clippy --all-targets --all-features -- -D warnings - name: Run tests run: cargo test --verbose diff --git a/src/commands/scan.rs b/src/commands/scan.rs index a5fa4e02..42cc9032 100644 --- a/src/commands/scan.rs +++ b/src/commands/scan.rs @@ -3,7 +3,7 @@ use crate::utils::project::get_project_info; use std::path::Path; use crate::utils::config::Config; use tree_sitter::{Parser}; -use crate::index::index::Indexer; +use crate::database::index::Indexer; use crate::walk::spawn_senders; pub fn handle( diff --git a/src/index.rs b/src/database.rs similarity index 100% rename from src/index.rs rename to src/database.rs diff --git a/src/main.rs b/src/main.rs index dbe0276e..bb097c4a 100644 --- a/src/main.rs +++ b/src/main.rs @@ -2,7 +2,7 @@ mod cli; mod commands; mod utils; mod walk; -mod index; +mod database; use crate::utils::Config; use cli::Cli;