From c6496a6b700b5026a0f4984486bd496cfef32044 Mon Sep 17 00:00:00 2001 From: Ali Hashemi Date: Mon, 6 Oct 2025 17:32:12 -0300 Subject: [PATCH 1/5] fix: duplicate tool name --- src/tools/calculate_directory_size.rs | 2 +- src/tools/create_directory.rs | 2 +- src/tools/directory_tree.rs | 2 +- src/tools/edit_file.rs | 2 +- src/tools/find_duplicate_files.rs | 2 +- src/tools/find_empty_directories.rs | 4 +-- src/tools/get_file_info.rs | 2 +- src/tools/list_allowed_directories.rs | 2 +- src/tools/list_directory.rs | 2 +- src/tools/list_directory_with_sizes.rs | 2 +- src/tools/move_file.rs | 2 +- src/tools/read_file_lines.rs | 4 +-- src/tools/read_multiple_media_files.rs | 2 +- src/tools/read_multiple_text_files.rs | 2 +- src/tools/search_file.rs | 2 +- src/tools/search_files_content.rs | 2 +- src/tools/tail_file.rs | 6 ++-- src/tools/write_file.rs | 2 +- src/tools/zip_unzip.rs | 2 +- tests/test_tools.rs | 38 +++++++++++++++++++++++++- 20 files changed, 60 insertions(+), 24 deletions(-) diff --git a/src/tools/calculate_directory_size.rs b/src/tools/calculate_directory_size.rs index af8d56c..4af70ea 100644 --- a/src/tools/calculate_directory_size.rs +++ b/src/tools/calculate_directory_size.rs @@ -15,7 +15,7 @@ pub enum FileSizeOutputFormat { #[mcp_tool( name = "calculate_directory_size", - title="Calculate Directory Size", + title="Calculate directory size", description = concat!("Calculates the total size of a directory specified by `root_path`.", "It recursively searches for files and sums their sizes. ", "The result can be returned in either a `human-readable` format or as `bytes`, depending on the specified `output_format` argument.", diff --git a/src/tools/create_directory.rs b/src/tools/create_directory.rs index 6fcbbc1..d4db74a 100644 --- a/src/tools/create_directory.rs +++ b/src/tools/create_directory.rs @@ -8,7 +8,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "create_directory", - title="Create Directory", + title="Create directory", description = concat!("Create a new directory or ensure a directory exists. ", "Can create multiple nested directories in one operation. ", "If the directory already exists, this operation will succeed silently. ", diff --git a/src/tools/directory_tree.rs b/src/tools/directory_tree.rs index 33cf29d..160526c 100644 --- a/src/tools/directory_tree.rs +++ b/src/tools/directory_tree.rs @@ -8,7 +8,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "directory_tree", - title= "Directory Tree", + title= "Directory tree", description = concat!("Get a recursive tree view of files and directories as a JSON structure. ", "Each entry includes 'name', 'type' (file/directory), and 'children' for directories. ", "Files have no children array, while directories always have a children array (which may be empty). ", diff --git a/src/tools/edit_file.rs b/src/tools/edit_file.rs index e59ceff..955e1c3 100644 --- a/src/tools/edit_file.rs +++ b/src/tools/edit_file.rs @@ -19,7 +19,7 @@ pub struct EditOperation { #[mcp_tool( name = "edit_file", - title="Edit File", + title="Edit file", description = concat!("Make line-based edits to a text file. ", "Each edit replaces exact line sequences with new content. ", "Returns a git-style diff showing the changes made. ", diff --git a/src/tools/find_duplicate_files.rs b/src/tools/find_duplicate_files.rs index 15465c0..d3c3828 100644 --- a/src/tools/find_duplicate_files.rs +++ b/src/tools/find_duplicate_files.rs @@ -8,7 +8,7 @@ use std::{collections::BTreeMap, fmt::Write}; #[mcp_tool( name = "find_duplicate_files", - title="Calculate Directory Size", + title="Find duplicate files", description = concat!("Find duplicate files within a directory and return list of duplicated files as text or json format", "Optional `pattern` argument can be used to narrow down the file search to specific glob pattern.", "Optional `exclude_patterns` can be used to exclude certain files matching a glob.", diff --git a/src/tools/find_empty_directories.rs b/src/tools/find_empty_directories.rs index 0b35b4e..dcfec43 100644 --- a/src/tools/find_empty_directories.rs +++ b/src/tools/find_empty_directories.rs @@ -7,10 +7,10 @@ use std::path::Path; use crate::fs_service::{FileSystemService, utils::OutputFormat}; -// head_file +// find_empty_directories #[mcp_tool( name = "find_empty_directories", - title="Find Empty Directories", + title="Find empty directories", description = concat!("Recursively finds all empty directories within the given root path.", "A directory is considered empty if it contains no files in itself or any of its subdirectories.", "Operating system metadata files `.DS_Store` (macOS) and `Thumbs.db` (Windows) will be ignored.", diff --git a/src/tools/get_file_info.rs b/src/tools/get_file_info.rs index 8d29309..07bc2e3 100644 --- a/src/tools/get_file_info.rs +++ b/src/tools/get_file_info.rs @@ -8,7 +8,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "get_file_info", - title="Get File Info", + title="Get file info", description = concat!("Retrieve detailed metadata about a file or directory. ", "Returns comprehensive information including size, creation time, ", "last modified time, permissions, and type. ", diff --git a/src/tools/list_allowed_directories.rs b/src/tools/list_allowed_directories.rs index 40ed8ee..613ef04 100644 --- a/src/tools/list_allowed_directories.rs +++ b/src/tools/list_allowed_directories.rs @@ -6,7 +6,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "list_allowed_directories", - title="List Allowed Directories", + title="List allowed directories", description = concat!("Returns a list of directories that the server has permission ", "to access Subdirectories within these allowed directories are also accessible. ", "Use this to identify which directories and their nested paths are available ", diff --git a/src/tools/list_directory.rs b/src/tools/list_directory.rs index e86ca3f..6669b37 100644 --- a/src/tools/list_directory.rs +++ b/src/tools/list_directory.rs @@ -8,7 +8,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "list_directory", - title="List Directory", + title="List directory", description = concat!("Get a detailed listing of all files and directories in a specified path. ", "Results clearly distinguish between files and directories with [FILE] and [DIR] ", "prefixes. This tool is essential for understanding directory structure and ", diff --git a/src/tools/list_directory_with_sizes.rs b/src/tools/list_directory_with_sizes.rs index 91bf2a8..a7cb55b 100644 --- a/src/tools/list_directory_with_sizes.rs +++ b/src/tools/list_directory_with_sizes.rs @@ -9,7 +9,7 @@ use crate::fs_service::utils::format_bytes; #[mcp_tool( name = "list_directory_with_sizes", - title="List Directory With File Sizes", + title="List directory with file sizes", description = concat!("Get a detailed listing of all files and directories in a specified path, including sizes. " , "Results clearly distinguish between files and directories with [FILE] and [DIR] prefixes. " , "This tool is useful for understanding directory structure and " , diff --git a/src/tools/move_file.rs b/src/tools/move_file.rs index 12d59ca..efa6b6b 100644 --- a/src/tools/move_file.rs +++ b/src/tools/move_file.rs @@ -8,7 +8,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "move_file", - title="Move File", + title="Move file", description = concat!("Move or rename files and directories. Can move files between directories ", "and rename them in a single operation. If the destination exists, the ", "operation will fail. Works across different directories and can be used ", diff --git a/src/tools/read_file_lines.rs b/src/tools/read_file_lines.rs index 86109d5..cff99dc 100644 --- a/src/tools/read_file_lines.rs +++ b/src/tools/read_file_lines.rs @@ -7,10 +7,10 @@ use rust_mcp_sdk::{ use crate::fs_service::FileSystemService; -// head_file +// read_file_lines #[mcp_tool( name = "read_file_lines", - title="Read File Lines", + title="Read file lines", description = concat!("Reads lines from a text file starting at a specified line offset (0-based) and continues for the specified number of lines if a limit is provided.", "This function skips the first 'offset' lines and then reads up to 'limit' lines if specified, or reads until the end of the file otherwise.", "It's useful for partial reads, pagination, or previewing sections of large text files.", diff --git a/src/tools/read_multiple_media_files.rs b/src/tools/read_multiple_media_files.rs index 38b64f7..43a5143 100644 --- a/src/tools/read_multiple_media_files.rs +++ b/src/tools/read_multiple_media_files.rs @@ -5,7 +5,7 @@ use rust_mcp_sdk::schema::{CallToolResult, schema_utils::CallToolError}; #[mcp_tool( name = "read_multiple_media_files", - title="Read Multiple Media (Image/Audio) Files", + title="Read multiple media (Image/Audio) files", description = concat!("Reads multiple image or audio files and returns their Base64-encoded contents along with corresponding MIME types. ", "This method is more efficient than reading files individually. ", "The max_bytes argument could be used to enforce an upper limit on the size of a file to read ", diff --git a/src/tools/read_multiple_text_files.rs b/src/tools/read_multiple_text_files.rs index 0389c78..91923e4 100644 --- a/src/tools/read_multiple_text_files.rs +++ b/src/tools/read_multiple_text_files.rs @@ -7,7 +7,7 @@ use std::path::Path; #[mcp_tool( name = "read_multiple_text_files", - title="Read Multiple Text Files", + title="Read multiple text files", description = concat!("Read the contents of multiple text files simultaneously as text. ", "This is more efficient than reading files one by one when you need to analyze ", "or compare multiple files. Each file's content is returned with its ", diff --git a/src/tools/search_file.rs b/src/tools/search_file.rs index 0bdd81c..34a569c 100644 --- a/src/tools/search_file.rs +++ b/src/tools/search_file.rs @@ -7,7 +7,7 @@ use rust_mcp_sdk::schema::{CallToolResult, schema_utils::CallToolError}; use crate::fs_service::FileSystemService; #[mcp_tool( name = "search_files", - title="Search Files", + title="Search files", description = concat!("Recursively search for files and directories matching a pattern. ", "Searches through all subdirectories from the starting path. The search is case-insensitive ", "and matches partial names. Returns full paths to all matching items.", diff --git a/src/tools/search_files_content.rs b/src/tools/search_files_content.rs index 85a371c..a5e2fd4 100644 --- a/src/tools/search_files_content.rs +++ b/src/tools/search_files_content.rs @@ -6,7 +6,7 @@ use rust_mcp_sdk::schema::{CallToolResult, schema_utils::CallToolError}; use std::fmt::Write; #[mcp_tool( name = "search_files_content", - title="Move Files Content", + title="Move files content", description = concat!("Searches for text or regex patterns in the content of files matching matching a GLOB pattern.", "Returns detailed matches with file path, line number, column number and a preview of matched text.", "By default, it performs a literal text search; if the 'is_regex' parameter is set to true, it performs a regular expression (regex) search instead.", diff --git a/src/tools/tail_file.rs b/src/tools/tail_file.rs index b808660..bc40e55 100644 --- a/src/tools/tail_file.rs +++ b/src/tools/tail_file.rs @@ -7,10 +7,10 @@ use rust_mcp_sdk::{ use crate::fs_service::FileSystemService; -// head_file +// tail_file #[mcp_tool( - name = "head_file", - title="Head file", + name = "tail_file", + title="Tail file", description = concat!("Reads and returns the last N lines of a text file.", "This is useful for quickly previewing file contents without loading the entire file into memory.", "If the file has fewer than N lines, the entire file will be returned.", diff --git a/src/tools/write_file.rs b/src/tools/write_file.rs index 3d09d53..77b8b4f 100644 --- a/src/tools/write_file.rs +++ b/src/tools/write_file.rs @@ -9,7 +9,7 @@ use rust_mcp_sdk::schema::{CallToolResult, schema_utils::CallToolError}; use crate::fs_service::FileSystemService; #[mcp_tool( name = "write_file", - title="Write File", + title="Write file", description = concat!("Create a new file or completely overwrite an existing file with new content. ", "Use with caution as it will overwrite existing files without warning. ", "Handles text content with proper encoding. Only works within allowed directories."), diff --git a/src/tools/zip_unzip.rs b/src/tools/zip_unzip.rs index b81e885..00b7b8b 100644 --- a/src/tools/zip_unzip.rs +++ b/src/tools/zip_unzip.rs @@ -6,7 +6,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "zip_files", - title="Zip Files", + title="Zip files", description = concat!("Creates a ZIP archive by compressing files. ", "It takes a list of files to compress and a target path for the resulting ZIP file. ", "Both the source files and the target ZIP file should reside within allowed directories."), diff --git a/tests/test_tools.rs b/tests/test_tools.rs index ef702cf..ef7b502 100644 --- a/tests/test_tools.rs +++ b/tests/test_tools.rs @@ -4,7 +4,7 @@ pub mod common; use common::setup_service; use rust_mcp_filesystem::tools::*; use rust_mcp_sdk::schema::{ContentBlock, schema_utils::CallToolError}; -use std::fs; +use std::{collections::HashSet, fs}; #[tokio::test] async fn test_create_directory_new_directory() { @@ -129,5 +129,41 @@ async fn test_create_directory_invalid_path() { assert!(matches!(err, CallToolError { .. })); } +// Github Issue #54 +// https://github.com/rust-mcp-stack/rust-mcp-filesystem/issues/54 +#[tokio::test] +async fn ensure_tools_duplication() { + let mut names = HashSet::new(); + let mut duplicate_names = vec![]; + + let mut titles = HashSet::new(); + let mut duplicate_titles = vec![]; + + let mut descriptions = HashSet::new(); + let mut duplicate_descriptions = vec![]; + + for t in FileSystemTools::tools() { + if !names.insert(t.name.to_string()) { + duplicate_names.push(t.name.to_string()); + } + + if let Some(title) = t.title { + if !titles.insert(title.to_string()) { + duplicate_titles.push(title.to_string()); + } + } + + if let Some(description) = t.description { + if !descriptions.insert(description.to_string()) { + duplicate_descriptions.push(description.to_string()); + } + } + } + + assert_eq!(duplicate_names.join(","), ""); + assert_eq!(duplicate_titles.join(","), ""); + assert_eq!(duplicate_descriptions.join(","), ""); +} + #[tokio::test] async fn adhoc() {} From ee6b0d27a90ab649e3cd93af8d066ac7f464ae37 Mon Sep 17 00:00:00 2001 From: Ali Hashemi Date: Wed, 15 Oct 2025 18:30:31 -0300 Subject: [PATCH 2/5] fix: docker image --- .github/workflows/docker.yml | 1 + Dockerfile | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml index c081c11..41efaa7 100644 --- a/.github/workflows/docker.yml +++ b/.github/workflows/docker.yml @@ -35,6 +35,7 @@ jobs: with: platforms: linux/amd64,linux/arm64 push: true + provenance: mode=max tags: | ${{ env.IMAGE_NAME }}:${{ inputs.version }} ${{ env.IMAGE_NAME }}:latest diff --git a/Dockerfile b/Dockerfile index 8d2f7b8..9a5efb9 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,9 +9,11 @@ COPY ./src ./src RUN cargo build --release RUN ls -lh target -FROM alpine +FROM alpine:latest COPY --from=builder /usr/src/app/target/*-unknown-linux-musl/release/rust-mcp-filesystem rust-mcp-filesystem -ENTRYPOINT ["./rust-mcp-filesystem"] +RUN adduser -D -s /bin/sh rust-mcp-user +USER rust-mcp-user +ENTRYPOINT ["./rust-mcp-filesystem"] From 7d621f923aa79e352bfe6479873b85859b5367cc Mon Sep 17 00:00:00 2001 From: Ali Hashemi Date: Fri, 31 Oct 2025 19:11:15 -0300 Subject: [PATCH 3/5] fix: respect mcp root command argument --- src/handler.rs | 34 +++++++++++++++++++++---------- src/tools/read_media_file.rs | 2 +- src/tools/search_files_content.rs | 2 +- 3 files changed, 25 insertions(+), 13 deletions(-) diff --git a/src/handler.rs b/src/handler.rs index 1855372..dba5501 100644 --- a/src/handler.rs +++ b/src/handler.rs @@ -70,23 +70,29 @@ impl FileSystemHandler { } pub(crate) async fn update_allowed_directories(&self, runtime: Arc) { - // if client does not support roots + // return if roots_support is not enabled + if !self.mcp_roots_support { + return; + } + let allowed_directories = self.fs_service.allowed_directories().await; + // if client does NOT support roots if !runtime.client_supports_root_list().unwrap_or(false) { + // use allowed directories from command line if !allowed_directories.is_empty() { - let _ = runtime.stderr_message(format!("Client does not support MCP Roots, using allowed directories set from server args:\n{}", allowed_directories - .iter() - .map(|p| p.display().to_string()) - .collect::>() - .join(",\n"))).await; + // display message only if mcp_roots_support is enabled, otherwise this message will be redundant + if self.mcp_roots_support { + let _ = runtime.stderr_message("Client does not support MCP Roots. Allowed directories passed from command-line will be used.".to_string()).await; + } } else { - // let message = "Server cannot operate: No allowed directories available. Server was started without command-line directories and client either does not support MCP roots protocol or provided empty roots. Please either: 1) Start server with directory arguments, or 2) Use a client that supports MCP roots protocol and provides valid root directories."; + // root lists not supported AND allowed directories are empty let message = "Server cannot operate: No allowed directories available. Server was started without command-line directories and client does not support MCP roots protocol. Please either: 1) Start server with directory arguments, or 2) Use a client that supports MCP roots protocol and provides valid root directories."; let _ = runtime.stderr_message(message.to_string()).await; + std::process::exit(1); // exit the server } } else { + // client supports roots let fs_service = self.fs_service.clone(); - let mcp_roots_support = self.mcp_roots_support; // retrieve roots from the client and update the allowed directories accordingly let roots = match runtime.clone().list_roots(None).await { Ok(roots_result) => roots_result.roots, @@ -111,7 +117,7 @@ impl FileSystemHandler { } }; - if valid_roots.is_empty() && !mcp_roots_support { + if valid_roots.is_empty() { let message = if allowed_directories.is_empty() { "Server cannot operate: No allowed directories available. Server was started without command-line directories and client provided empty roots. Please either: 1) Start server with directory arguments, or 2) Use a client that supports MCP roots protocol and provides valid root directories." } else { @@ -120,7 +126,6 @@ impl FileSystemHandler { let _ = runtime.stderr_message(message.to_string()).await; } else { let num_valid_roots = valid_roots.len(); - fs_service.update_allowed_paths(valid_roots).await; let message = format!( "Updated allowed directories from MCP roots: {num_valid_roots} valid directories", @@ -142,7 +147,14 @@ impl ServerHandler for FileSystemHandler { _notification: RootsListChangedNotification, runtime: Arc, ) -> std::result::Result<(), RpcError> { - self.update_allowed_directories(runtime).await; + if self.mcp_roots_support { + self.update_allowed_directories(runtime).await; + } else { + let message = + "Skipping ROOTS client updates, server launched without the --enable-roots flag." + .to_string(); + let _ = runtime.stderr_message(message).await; + }; Ok(()) } diff --git a/src/tools/read_media_file.rs b/src/tools/read_media_file.rs index 28a288d..0b8891d 100644 --- a/src/tools/read_media_file.rs +++ b/src/tools/read_media_file.rs @@ -9,7 +9,7 @@ use crate::fs_service::FileSystemService; #[mcp_tool( name = "read_media_file", - title="Read an Image or Audio file", + title="Read a media (Image/Audio) file", description = concat!("Reads an image or audio file and returns its Base64-encoded content along with the corresponding MIME type. ", "The max_bytes argument could be used to enforce an upper limit on the size of a file to read ", "if the media file exceeds this limit, the operation will return an error instead of reading the media file. ", diff --git a/src/tools/search_files_content.rs b/src/tools/search_files_content.rs index a5e2fd4..4824daf 100644 --- a/src/tools/search_files_content.rs +++ b/src/tools/search_files_content.rs @@ -6,7 +6,7 @@ use rust_mcp_sdk::schema::{CallToolResult, schema_utils::CallToolError}; use std::fmt::Write; #[mcp_tool( name = "search_files_content", - title="Move files content", + title="Search files content", description = concat!("Searches for text or regex patterns in the content of files matching matching a GLOB pattern.", "Returns detailed matches with file path, line number, column number and a preview of matched text.", "By default, it performs a literal text search; if the 'is_regex' parameter is set to true, it performs a regular expression (regex) search instead.", From d904b157c70423fb74d5f0c8e46d5d13c1e8e216 Mon Sep 17 00:00:00 2001 From: Ali Hashemi Date: Fri, 31 Oct 2025 19:27:32 -0300 Subject: [PATCH 4/5] fix: dependencies --- Cargo.lock | 435 ++++++++++++++++++----------------------------------- 1 file changed, 144 insertions(+), 291 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index bea0a9a..8c7d802 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2,15 +2,6 @@ # It is not intended for manual editing. version = 4 -[[package]] -name = "addr2line" -version = "0.25.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1b5d307320b3181d6d7954e663bd7c774a838b8220fe0593c86d9fb09f498b4b" -dependencies = [ - "gimli", -] - [[package]] name = "adler2" version = "2.0.1" @@ -19,9 +10,9 @@ checksum = "320119579fcad9c21884f5c4861d16174d0e06250625266f50fe6898340abefa" [[package]] name = "aho-corasick" -version = "1.1.3" +version = "1.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" +checksum = "ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301" dependencies = [ "memchr", ] @@ -131,21 +122,6 @@ version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8" -[[package]] -name = "backtrace" -version = "0.3.76" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb531853791a215d7c62a30daf0dde835f381ab5de4589cfe7c649d2cbe92bd6" -dependencies = [ - "addr2line", - "cfg-if", - "libc", - "miniz_oxide", - "object", - "rustc-demangle", - "windows-link", -] - [[package]] name = "base64" version = "0.22.1" @@ -154,9 +130,9 @@ checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" [[package]] name = "bitflags" -version = "2.9.4" +version = "2.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2261d10cca569e4643e526d8dc2e62e433cc8aba21ab764233731f8d369bf394" +checksum = "812e12b5285cc515a9c72a5c1d3b6d46a19dac5acfef5265968c166106e31dd3" [[package]] name = "block-buffer" @@ -169,9 +145,9 @@ dependencies = [ [[package]] name = "bstr" -version = "1.12.0" +version = "1.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "234113d19d0d7d613b40e86fb654acf958910802bcceab913a4f9e7cda03b1a4" +checksum = "63044e1ae8e69f3b5a92c736ca6269b8d12fa7efe39bf34ddb06d102cf0e2cab" dependencies = [ "memchr", "regex-automata", @@ -198,18 +174,18 @@ checksum = "d71b6127be86fdcfddb610f7182ac57211d4b18a3e9c82eb2d17662f2227ad6a" [[package]] name = "bzip2" -version = "0.6.0" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bea8dcd42434048e4f7a304411d9273a411f647446c1234a65ce0554923f4cff" +checksum = "f3a53fac24f34a81bc9954b5d6cfce0c21e18ec6959f44f56e8e90e4bb7c346c" dependencies = [ "libbz2-rs-sys", ] [[package]] name = "cc" -version = "1.2.40" +version = "1.2.44" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e1d05d92f4b1fd76aad469d46cdd858ca761576082cd37df81416691e50199fb" +checksum = "37521ac7aabe3d13122dc382493e20c9416f299d2ccd5b3a5340a2570cdeb0f3" dependencies = [ "find-msvc-tools", "jobserver", @@ -230,9 +206,9 @@ dependencies = [ [[package]] name = "cfg-if" -version = "1.0.3" +version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fd1289c04a9ea8cb22300a459a72a385d7c73d3259e2ed7dcb2af674838cfa9" +checksum = "9330f8b2ff13f34540b44e946ef35111825727b38d33286ef986142615121801" [[package]] name = "chrono" @@ -249,9 +225,9 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.48" +version = "4.5.51" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2134bb3ea021b78629caa971416385309e0131b351b25e01dc16fb54e1b5fae" +checksum = "4c26d721170e0295f191a69bd9a1f93efcdb0aff38684b61ab5750468972e5f5" dependencies = [ "clap_builder", "clap_derive", @@ -259,9 +235,9 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.48" +version = "4.5.51" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c2ba64afa3c0a6df7fa517765e31314e983f51dda798ffba27b988194fb65dc9" +checksum = "75835f0c7bf681bfd05abe44e965760fea999a5286c6eb2d59883634fd02011a" dependencies = [ "anstream", "anstyle", @@ -271,9 +247,9 @@ dependencies = [ [[package]] name = "clap_derive" -version = "4.5.47" +version = "4.5.49" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bbfd7eae0b0f1a6e63d4b13c9c478de77c2eb546fba158ad50b4203dc24b9f9c" +checksum = "2a0b5487afeab2deb2ff4e03a807ad1a03ac532ff5a2cee5d86884440c7f7671" dependencies = [ "heck", "proc-macro2", @@ -283,9 +259,9 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.7.5" +version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b94f61472cee1439c0b966b47e3aca9ae07e45d070759512cd390ea2bebc6675" +checksum = "a1d728cc89cf3aee9ff92b05e62b19ee65a02b5702cff7d5a377e32c6ae29d8d" [[package]] name = "colorchoice" @@ -407,7 +383,7 @@ dependencies = [ "libc", "option-ext", "redox_users", - "windows-sys 0.61.1", + "windows-sys 0.61.2", ] [[package]] @@ -441,7 +417,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb" dependencies = [ "libc", - "windows-sys 0.61.1", + "windows-sys 0.61.2", ] [[package]] @@ -452,15 +428,15 @@ checksum = "37909eebbb50d72f9059c3b6d82c0463f2ff062c9e95845c43a6c9c0355411be" [[package]] name = "find-msvc-tools" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0399f9d26e5191ce32c498bebd31e7a3ceabc2745f0ac54af3f335126c3f24b3" +checksum = "52051878f80a721bb68ebfbc930e07b65ba72f2da88968ea5c06fd6ca3d3a127" [[package]] name = "flate2" -version = "1.1.2" +version = "1.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4a3d7db9596fecd151c5f638c0ee5d5bd487b6e0ea232e5dc96d5250f6f94b1d" +checksum = "bfe33edd8e85a12a67454e37f8c75e730830d83e313556ab9ebf9ee7fbeb3bfb" dependencies = [ "crc32fast", "miniz_oxide", @@ -576,9 +552,9 @@ dependencies = [ [[package]] name = "generic-array" -version = "0.14.7" +version = "0.14.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" +checksum = "4bb6743198531e02858aeaea5398fcc883e71851fcbcb5a2f773e2fb6cb1edf2" dependencies = [ "typenum", "version_check", @@ -592,27 +568,21 @@ checksum = "335ff9f135e4384c8150d6f27c6daed433577f86b4750418338c01a1a2528592" dependencies = [ "cfg-if", "libc", - "wasi 0.11.1+wasi-snapshot-preview1", + "wasi", ] [[package]] name = "getrandom" -version = "0.3.3" +version = "0.3.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "26145e563e54f2cadc477553f1ec5ee650b00862f0a58bcd12cbdc5f0ea2d2f4" +checksum = "899def5c37c4fd7b2664648c28120ecec138e4d395b459e5ca34f9cce2dd77fd" dependencies = [ "cfg-if", "libc", "r-efi", - "wasi 0.14.7+wasi-0.2.4", + "wasip2", ] -[[package]] -name = "gimli" -version = "0.32.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e629b9b98ef3dd8afe6ca2bd0f89306cec16d43d907889945bc5d6687f2f13c7" - [[package]] name = "glob-match" version = "0.2.1" @@ -621,9 +591,9 @@ checksum = "9985c9503b412198aa4197559e9a318524ebc4519c229bfa05a535828c950b9d" [[package]] name = "globset" -version = "0.4.16" +version = "0.4.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "54a1028dfc5f5df5da8a56a73e6c153c9a9708ec57232470703592a3f18e49f5" +checksum = "52dfc19153a48bde0cbd630453615c8151bce3a5adfac7a0aebfbf0a1e1f57e3" dependencies = [ "aho-corasick", "bstr", @@ -647,9 +617,9 @@ dependencies = [ [[package]] name = "grep-cli" -version = "0.1.11" +version = "0.1.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47f1288f0e06f279f84926fa4c17e3fcd2a22b357927a82f2777f7be26e4cec0" +checksum = "cf32d263c5d5cc2a23ce587097f5ddafdb188492ba2e6fb638eaccdc22453631" dependencies = [ "bstr", "globset", @@ -661,9 +631,9 @@ dependencies = [ [[package]] name = "grep-matcher" -version = "0.1.7" +version = "0.1.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47a3141a10a43acfedc7c98a60a834d7ba00dfe7bec9071cbfc19b55b292ac02" +checksum = "36d7b71093325ab22d780b40d7df3066ae4aebb518ba719d38c697a8228a8023" dependencies = [ "memchr", ] @@ -685,9 +655,9 @@ dependencies = [ [[package]] name = "grep-regex" -version = "0.1.13" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9edd147c7e3296e7a26bd3a81345ce849557d5a8e48ed88f736074e760f91f7e" +checksum = "0ce0c256c3ad82bcc07b812c15a45ec1d398122e8e15124f96695234db7112ef" dependencies = [ "bstr", "grep-matcher", @@ -698,9 +668,9 @@ dependencies = [ [[package]] name = "grep-searcher" -version = "0.1.14" +version = "0.1.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b9b6c14b3fc2e0a107d6604d3231dec0509e691e62447104bc385a46a7892cda" +checksum = "ac63295322dc48ebb20a25348147905d816318888e64f531bfc2a2bc0577dc34" dependencies = [ "bstr", "encoding_rs", @@ -750,22 +720,11 @@ dependencies = [ "cfb", ] -[[package]] -name = "io-uring" -version = "0.7.10" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "046fa2d4d00aea763528b4950358d0ead425372445dc8ff86312b3c69ff7727b" -dependencies = [ - "bitflags", - "cfg-if", - "libc", -] - [[package]] name = "is_terminal_polyfill" -version = "1.70.1" +version = "1.70.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" +checksum = "a6cb138bb79a146c1bd460005623e142ef0181e3d0219cb493e02f7d08a35695" [[package]] name = "itoa" @@ -779,15 +738,15 @@ version = "0.1.34" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9afb3de4395d6b3e67a780b6de64b51c978ecf11cb9a462c66be7d4ca9039d33" dependencies = [ - "getrandom 0.3.3", + "getrandom 0.3.4", "libc", ] [[package]] name = "js-sys" -version = "0.3.81" +version = "0.3.82" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec48937a97411dcb524a265206ccd4c90bb711fca92b2792c407f268825b9305" +checksum = "b011eec8cc36da2aab2d5cff675ec18454fad408585853910a202391cf9f8e65" dependencies = [ "once_cell", "wasm-bindgen", @@ -801,9 +760,9 @@ checksum = "2c4a545a15244c7d945065b5d392b2d2d7f21526fba56ce51467b06ed445e8f7" [[package]] name = "libc" -version = "0.2.176" +version = "0.2.177" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58f929b4d672ea937a23a1ab494143d968337a5f47e56d0815df1e0890ddf174" +checksum = "2874a2af47a2325c2001a6e6fad9b16a53b802102b528163885171cf92b15976" [[package]] name = "liblzma" @@ -864,9 +823,9 @@ checksum = "f52b00d39961fc5b2736ea853c9cc86238e165017a493d1d5c8eac6bdc4cc273" [[package]] name = "memmap2" -version = "0.9.8" +version = "0.9.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "843a98750cd611cc2965a8213b53b43e715f13c37a9e096c6408e69990961db7" +checksum = "744133e4a0e0a658e1374cf3bf8e415c4052a15a111acd372764c55b4177d490" dependencies = [ "libc", ] @@ -878,17 +837,18 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "1fa76a2c86f704bdb222d66965fb3d63269ce38518b83cb0575fca855ebb6316" dependencies = [ "adler2", + "simd-adler32", ] [[package]] name = "mio" -version = "1.0.4" +version = "1.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78bed444cc8a2160f01cbcf811ef18cac863ad68ae8ca62092e8db51d51c761c" +checksum = "69d83b0086dc8ecf3ce9ae2874b2d1290252e2a30720bea58a5c6639b0092873" dependencies = [ "libc", - "wasi 0.11.1+wasi-snapshot-preview1", - "windows-sys 0.59.0", + "wasi", + "windows-sys 0.61.2", ] [[package]] @@ -900,15 +860,6 @@ dependencies = [ "autocfg", ] -[[package]] -name = "object" -version = "0.37.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ff76201f031d8863c38aa7f905eca4f53abbfa15f609db4277d44cd8938f33fe" -dependencies = [ - "memchr", -] - [[package]] name = "once_cell" version = "1.21.3" @@ -917,9 +868,9 @@ checksum = "42f5e15c9953c5e4ccceeb2e7382a716482c34515315f7b03532b8b4e8393d2d" [[package]] name = "once_cell_polyfill" -version = "1.70.1" +version = "1.70.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4895175b425cb1f87721b59f0f286c2092bd4af812243672510e1ac53e2e0ad" +checksum = "384b8ab6d37215f3c5301a95a4accb5d64aa607f1fcb26a11b5303878451b4fe" [[package]] name = "option-ext" @@ -996,9 +947,9 @@ checksum = "7edddbd0b52d732b21ad9a5fab5c704c14cd949e5e9a1ec5929a24fded1b904c" [[package]] name = "proc-macro2" -version = "1.0.101" +version = "1.0.103" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89ae43fd86e4158d6db51ad8e2b80f313af9cc74f5c0e03ccb87de09998732de" +checksum = "5ee95bc4ef87b8d5ba32e8b7714ccc834865276eab0aed5c9958d00ec45f49e8" dependencies = [ "unicode-ident", ] @@ -1040,9 +991,9 @@ dependencies = [ [[package]] name = "redox_syscall" -version = "0.5.17" +version = "0.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5407465600fb0548f1442edf71dd20683c6ed326200ace4b1ef0763521bb3b77" +checksum = "ed2bf2547551a7053d6fdfafda3f938979645c44812fbfcda098faae3f1a362d" dependencies = [ "bitflags", ] @@ -1060,9 +1011,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.11" +version = "0.4.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "833eb9ce86d40ef33cb1306d8accf7bc8ec2bfea4355cbdebb3df68b40925cad" +checksum = "5276caf25ac86c8d810222b3dbb938e512c55c6831a10f3e6ed1c93b84041f1c" dependencies = [ "aho-corasick", "memchr", @@ -1071,9 +1022,9 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.8.6" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "caf4aa5b0f434c91fe5c7f1ecb6a5ece2130b02ad2a590589dda5146df959001" +checksum = "7a2d987857b319362043e95f5353c0535c1f58eec5336fdfcf626430af7def58" [[package]] name = "rust-mcp-filesystem" @@ -1127,12 +1078,13 @@ dependencies = [ [[package]] name = "rust-mcp-sdk" -version = "0.7.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "961ec01d0bedecf488388e6b1cf04170f9badab4927061c6592ffa385c02c6c9" +checksum = "98db95d9bb76c17fb263b6ddb63105de52223f5521878ba218b3c1e59408f5a7" dependencies = [ "async-trait", "base64", + "bytes", "futures", "rust-mcp-macros", "rust-mcp-schema", @@ -1147,9 +1099,9 @@ dependencies = [ [[package]] name = "rust-mcp-transport" -version = "0.6.0" +version = "0.6.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "35feabc5e4667019dc262178724c94cbced6f43959af15e214b52f79243f55ed" +checksum = "b9be7b63ad5155c134856e1ffdb4bc1df00324eb4f23c6f314e6a6c03606a4a4" dependencies = [ "async-trait", "bytes", @@ -1163,12 +1115,6 @@ dependencies = [ "tracing", ] -[[package]] -name = "rustc-demangle" -version = "0.1.26" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56f7d92ca342cea22a06f2121d944b4fd82af56988c270852495420f961d4ace" - [[package]] name = "rustix" version = "1.1.2" @@ -1179,7 +1125,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys", - "windows-sys 0.61.1", + "windows-sys 0.61.2", ] [[package]] @@ -1278,6 +1224,12 @@ dependencies = [ "libc", ] +[[package]] +name = "simd-adler32" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d66dc143e6b11c1eddc06d5c423cfc97062865baf299914ab64caa38182078fe" + [[package]] name = "similar" version = "2.7.0" @@ -1298,12 +1250,12 @@ checksum = "67b1b7a3b5fe4f1376887184045fcf45c69e92af734b7aaddc05fb777b6fbd03" [[package]] name = "socket2" -version = "0.6.0" +version = "0.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233504af464074f9d066d7b5416c5f9b894a5862a6506e306f7b816cdd6f1807" +checksum = "17129e116933cf371d018bb80ae557e889637989d8638274fb25622827b03881" dependencies = [ "libc", - "windows-sys 0.59.0", + "windows-sys 0.60.2", ] [[package]] @@ -1314,9 +1266,9 @@ checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" [[package]] name = "syn" -version = "2.0.106" +version = "2.0.108" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ede7c438028d4436d71104916910f5bb611972c5cfd7f89b8300a8186e6fada6" +checksum = "da58917d35242480a05c2897064da0a80589a2a0476c9a3f2fdc83b53502e917" dependencies = [ "proc-macro2", "quote", @@ -1330,10 +1282,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2d31c77bdf42a745371d260a26ca7163f1e0924b64afa0b688e61b5a9fa02f16" dependencies = [ "fastrand", - "getrandom 0.3.3", + "getrandom 0.3.4", "once_cell", "rustix", - "windows-sys 0.61.1", + "windows-sys 0.61.2", ] [[package]] @@ -1367,29 +1319,26 @@ dependencies = [ [[package]] name = "tokio" -version = "1.47.1" +version = "1.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "89e49afdadebb872d3145a5638b59eb0691ea23e46ca484037cfab3b76b95038" +checksum = "ff360e02eab121e0bc37a2d3b4d4dc622e6eda3a8e5253d5435ecf5bd4c68408" dependencies = [ - "backtrace", "bytes", - "io-uring", "libc", "mio", "parking_lot", "pin-project-lite", "signal-hook-registry", - "slab", "socket2", "tokio-macros", - "windows-sys 0.59.0", + "windows-sys 0.61.2", ] [[package]] name = "tokio-macros" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e06d43f1345a3bcd39f6a56dbb7dcab2ba47e68e8ac134855e7e2bdbaf8cab8" +checksum = "af407857209536a95c8e56f8231ef2c2e2aff839b22e07a1ffcbc617e9db9fa5" dependencies = [ "proc-macro2", "quote", @@ -1460,9 +1409,9 @@ checksum = "562d481066bde0658276a35467c4af00bdc6ee726305698a55b86e61d7ad82bb" [[package]] name = "unicode-ident" -version = "1.0.19" +version = "1.0.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f63a545481291138910575129486daeaf8ac54aee4387fe7906919f7830c7d9d" +checksum = "9312f7c4f6ff9069b165498234ce8be658059c6728633667c526e27dc2cf1df5" [[package]] name = "utf8parse" @@ -1476,7 +1425,7 @@ version = "1.18.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2f87b8aa10b915a06587d0dec516c282ff295b475d94abf425d62b57710070a2" dependencies = [ - "getrandom 0.3.3", + "getrandom 0.3.4", "js-sys", "wasm-bindgen", ] @@ -1503,15 +1452,6 @@ version = "0.11.1+wasi-snapshot-preview1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ccf3ec651a847eb01de73ccad15eb7d99f80485de043efb2f370cd654f4ea44b" -[[package]] -name = "wasi" -version = "0.14.7+wasi-0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "883478de20367e224c0090af9cf5f9fa85bed63a95c1abf3afc5c083ebc06e8c" -dependencies = [ - "wasip2", -] - [[package]] name = "wasip2" version = "1.0.1+wasi-0.2.4" @@ -1523,9 +1463,9 @@ dependencies = [ [[package]] name = "wasm-bindgen" -version = "0.2.104" +version = "0.2.105" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1da10c01ae9f1ae40cbfac0bac3b1e724b320abfcf52229f80b547c0d250e2d" +checksum = "da95793dfc411fbbd93f5be7715b0578ec61fe87cb1a42b12eb625caa5c5ea60" dependencies = [ "cfg-if", "once_cell", @@ -1534,25 +1474,11 @@ dependencies = [ "wasm-bindgen-shared", ] -[[package]] -name = "wasm-bindgen-backend" -version = "0.2.104" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "671c9a5a66f49d8a47345ab942e2cb93c7d1d0339065d4f8139c486121b43b19" -dependencies = [ - "bumpalo", - "log", - "proc-macro2", - "quote", - "syn", - "wasm-bindgen-shared", -] - [[package]] name = "wasm-bindgen-macro" -version = "0.2.104" +version = "0.2.105" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ca60477e4c59f5f2986c50191cd972e3a50d8a95603bc9434501cf156a9a119" +checksum = "04264334509e04a7bf8690f2384ef5265f05143a4bff3889ab7a3269adab59c2" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -1560,22 +1486,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.104" +version = "0.2.105" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9f07d2f20d4da7b26400c9f4a0511e6e0345b040694e8a75bd41d578fa4421d7" +checksum = "420bc339d9f322e562942d52e115d57e950d12d88983a14c79b86859ee6c7ebc" dependencies = [ + "bumpalo", "proc-macro2", "quote", "syn", - "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.104" +version = "0.2.105" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bad67dc8b2a1a6e5448428adec4c3e84c43e561d8c9ee8a9e5aabeb193ec41d1" +checksum = "76f218a38c84bcb33c25ec7059b07847d465ce0e0a76b995e134a45adcb6af76" dependencies = [ "unicode-ident", ] @@ -1586,14 +1512,14 @@ version = "0.1.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c2a7b1c03c876122aa43f3020e6c3c3ee5c05081c9a00739faf7503aeba10d22" dependencies = [ - "windows-sys 0.61.1", + "windows-sys 0.61.2", ] [[package]] name = "windows-core" -version = "0.62.1" +version = "0.62.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6844ee5416b285084d3d3fffd743b925a6c9385455f64f6d4fa3031c4c2749a9" +checksum = "b8e83a14d34d0623b51dce9581199302a221863196a1dde71a7663a4c2be9deb" dependencies = [ "windows-implement", "windows-interface", @@ -1604,9 +1530,9 @@ dependencies = [ [[package]] name = "windows-implement" -version = "0.60.1" +version = "0.60.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "edb307e42a74fb6de9bf3a02d9712678b22399c87e6fa869d6dfcd8c1b7754e0" +checksum = "053e2e040ab57b9dc951b72c264860db7eb3b0200ba345b4e4c3b14f67855ddf" dependencies = [ "proc-macro2", "quote", @@ -1615,9 +1541,9 @@ dependencies = [ [[package]] name = "windows-interface" -version = "0.59.2" +version = "0.59.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0abd1ddbc6964ac14db11c7213d6532ef34bd9aa042c2e5935f59d7908b46a5" +checksum = "3f316c4a2570ba26bbec722032c4099d8c8bc095efccdc15688708623367e358" dependencies = [ "proc-macro2", "quote", @@ -1626,183 +1552,110 @@ dependencies = [ [[package]] name = "windows-link" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45e46c0661abb7180e7b9c281db115305d49ca1709ab8242adf09666d2173c65" +checksum = "f0805222e57f7521d6a62e36fa9163bc891acd422f971defe97d64e70d0a4fe5" [[package]] name = "windows-result" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7084dcc306f89883455a206237404d3eaf961e5bd7e0f312f7c91f57eb44167f" +checksum = "7781fa89eaf60850ac3d2da7af8e5242a5ea78d1a11c49bf2910bb5a73853eb5" dependencies = [ "windows-link", ] [[package]] name = "windows-strings" -version = "0.5.0" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7218c655a553b0bed4426cf54b20d7ba363ef543b52d515b3e48d7fd55318dda" +checksum = "7837d08f69c77cf6b07689544538e017c1bfcf57e34b4c0ff58e6c2cd3b37091" dependencies = [ "windows-link", ] -[[package]] -name = "windows-sys" -version = "0.59.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" -dependencies = [ - "windows-targets 0.52.6", -] - [[package]] name = "windows-sys" version = "0.60.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb" dependencies = [ - "windows-targets 0.53.4", + "windows-targets", ] [[package]] name = "windows-sys" -version = "0.61.1" +version = "0.61.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f109e41dd4a3c848907eb83d5a42ea98b3769495597450cf6d153507b166f0f" +checksum = "ae137229bcbd6cdf0f7b80a31df61766145077ddf49416a728b02cb3921ff3fc" dependencies = [ "windows-link", ] [[package]] name = "windows-targets" -version = "0.52.6" +version = "0.53.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" -dependencies = [ - "windows_aarch64_gnullvm 0.52.6", - "windows_aarch64_msvc 0.52.6", - "windows_i686_gnu 0.52.6", - "windows_i686_gnullvm 0.52.6", - "windows_i686_msvc 0.52.6", - "windows_x86_64_gnu 0.52.6", - "windows_x86_64_gnullvm 0.52.6", - "windows_x86_64_msvc 0.52.6", -] - -[[package]] -name = "windows-targets" -version = "0.53.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2d42b7b7f66d2a06854650af09cfdf8713e427a439c97ad65a6375318033ac4b" +checksum = "4945f9f551b88e0d65f3db0bc25c33b8acea4d9e41163edf90dcd0b19f9069f3" dependencies = [ "windows-link", - "windows_aarch64_gnullvm 0.53.0", - "windows_aarch64_msvc 0.53.0", - "windows_i686_gnu 0.53.0", - "windows_i686_gnullvm 0.53.0", - "windows_i686_msvc 0.53.0", - "windows_x86_64_gnu 0.53.0", - "windows_x86_64_gnullvm 0.53.0", - "windows_x86_64_msvc 0.53.0", + "windows_aarch64_gnullvm", + "windows_aarch64_msvc", + "windows_i686_gnu", + "windows_i686_gnullvm", + "windows_i686_msvc", + "windows_x86_64_gnu", + "windows_x86_64_gnullvm", + "windows_x86_64_msvc", ] [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" - -[[package]] -name = "windows_aarch64_gnullvm" -version = "0.53.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b8d5f90ddd19cb4a147a5fa63ca848db3df085e25fee3cc10b39b6eebae764" - -[[package]] -name = "windows_aarch64_msvc" -version = "0.52.6" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" +checksum = "a9d8416fa8b42f5c947f8482c43e7d89e73a173cead56d044f6a56104a6d1b53" [[package]] name = "windows_aarch64_msvc" -version = "0.53.0" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c7651a1f62a11b8cbd5e0d42526e55f2c99886c77e007179efff86c2b137e66c" +checksum = "b9d782e804c2f632e395708e99a94275910eb9100b2114651e04744e9b125006" [[package]] name = "windows_i686_gnu" -version = "0.52.6" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" - -[[package]] -name = "windows_i686_gnu" -version = "0.53.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1dc67659d35f387f5f6c479dc4e28f1d4bb90ddd1a5d3da2e5d97b42d6272c3" +checksum = "960e6da069d81e09becb0ca57a65220ddff016ff2d6af6a223cf372a506593a3" [[package]] name = "windows_i686_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" - -[[package]] -name = "windows_i686_gnullvm" -version = "0.53.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ce6ccbdedbf6d6354471319e781c0dfef054c81fbc7cf83f338a4296c0cae11" - -[[package]] -name = "windows_i686_msvc" -version = "0.52.6" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" +checksum = "fa7359d10048f68ab8b09fa71c3daccfb0e9b559aed648a8f95469c27057180c" [[package]] name = "windows_i686_msvc" -version = "0.53.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "581fee95406bb13382d2f65cd4a908ca7b1e4c2f1917f143ba16efe98a589b5d" - -[[package]] -name = "windows_x86_64_gnu" -version = "0.52.6" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" +checksum = "1e7ac75179f18232fe9c285163565a57ef8d3c89254a30685b57d83a38d326c2" [[package]] name = "windows_x86_64_gnu" -version = "0.53.0" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e55b5ac9ea33f2fc1716d1742db15574fd6fc8dadc51caab1c16a3d3b4190ba" +checksum = "9c3842cdd74a865a8066ab39c8a7a473c0778a3f29370b5fd6b4b9aa7df4a499" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.6" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" - -[[package]] -name = "windows_x86_64_gnullvm" -version = "0.53.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a6e035dd0599267ce1ee132e51c27dd29437f63325753051e71dd9e42406c57" - -[[package]] -name = "windows_x86_64_msvc" -version = "0.52.6" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" +checksum = "0ffa179e2d07eee8ad8f57493436566c7cc30ac536a3379fdf008f47f6bb7ae1" [[package]] name = "windows_x86_64_msvc" -version = "0.53.0" +version = "0.53.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "271414315aff87387382ec3d271b52d7ae78726f5d44ac98b4f4030c91880486" +checksum = "d6bbff5f0aada427a1e5a6da5f1f98158182f26556f345ac9e04d36d0ebed650" [[package]] name = "wit-bindgen" From 5f03a4062d7fb43a88a7396a697c696df41910d6 Mon Sep 17 00:00:00 2001 From: Ali Hashemi Date: Fri, 31 Oct 2025 19:36:11 -0300 Subject: [PATCH 5/5] chore: update toolchain --- rust-toolchain.toml | 2 +- src/fs_service.rs | 28 +++++++++++++--------------- src/fs_service/utils.rs | 10 +++++----- tests/test_tools.rs | 16 ++++++++-------- 4 files changed, 27 insertions(+), 29 deletions(-) diff --git a/rust-toolchain.toml b/rust-toolchain.toml index 7855e6d..908d2ec 100644 --- a/rust-toolchain.toml +++ b/rust-toolchain.toml @@ -1,3 +1,3 @@ [toolchain] -channel = "1.88.0" +channel = "1.89.0" components = ["rustfmt", "clippy"] diff --git a/src/fs_service.rs b/src/fs_service.rs index 8797ae7..c9e1f4a 100644 --- a/src/fs_service.rs +++ b/src/fs_service.rs @@ -792,10 +792,10 @@ impl FileSystemService { *current_count += 1; // Check if we've exceeded max_files (if set) - if let Some(max) = max_files { - if *current_count > max { - continue; // Skip this entry but continue processing others - } + if let Some(max) = max_files + && *current_count > max + { + continue; // Skip this entry but continue processing others } let mut json_entry = json!({ @@ -1463,10 +1463,8 @@ impl FileSystemService { .filter_map(|e| e.ok()) .all(|e| !e.file_type().is_file() || is_system_metadata_file(e.file_name())); // Directory is empty if no files are found in it or subdirs, ".DS_Store" will be ignores on Mac - if is_empty { - if let Some(path_str) = entry.path().to_str() { - empty_dirs.push(path_str.to_string()); - } + if is_empty && let Some(path_str) = entry.path().to_str() { + empty_dirs.push(path_str.to_string()); } } @@ -1505,13 +1503,13 @@ impl FileSystemService { .filter(|e| e.file_type().is_file()); // Only files for entry in entries { - if let Ok(metadata) = entry.metadata() { - if let Some(path_str) = entry.path().to_str() { - size_map - .entry(metadata.len()) - .or_default() - .push(path_str.to_string()); - } + if let Ok(metadata) = entry.metadata() + && let Some(path_str) = entry.path().to_str() + { + size_map + .entry(metadata.len()) + .or_default() + .push(path_str.to_string()); } } diff --git a/src/fs_service/utils.rs b/src/fs_service/utils.rs index a7ca00c..eb8b641 100644 --- a/src/fs_service/utils.rs +++ b/src/fs_service/utils.rs @@ -66,11 +66,11 @@ pub fn normalize_path(path: &Path) -> PathBuf { } pub fn expand_home(path: PathBuf) -> PathBuf { - if let Some(home_dir) = home_dir() { - if path.starts_with("~") { - let stripped_path = path.strip_prefix("~").unwrap_or(&path); - return home_dir.join(stripped_path); - } + if let Some(home_dir) = home_dir() + && path.starts_with("~") + { + let stripped_path = path.strip_prefix("~").unwrap_or(&path); + return home_dir.join(stripped_path); } path } diff --git a/tests/test_tools.rs b/tests/test_tools.rs index ef7b502..c1acbbe 100644 --- a/tests/test_tools.rs +++ b/tests/test_tools.rs @@ -147,16 +147,16 @@ async fn ensure_tools_duplication() { duplicate_names.push(t.name.to_string()); } - if let Some(title) = t.title { - if !titles.insert(title.to_string()) { - duplicate_titles.push(title.to_string()); - } + if let Some(title) = t.title + && !titles.insert(title.to_string()) + { + duplicate_titles.push(title.to_string()); } - if let Some(description) = t.description { - if !descriptions.insert(description.to_string()) { - duplicate_descriptions.push(description.to_string()); - } + if let Some(description) = t.description + && !descriptions.insert(description.to_string()) + { + duplicate_descriptions.push(description.to_string()); } }