From bfb0358c533f994b78bca32abb17a7fd8f6ef765 Mon Sep 17 00:00:00 2001 From: Jakub Panek Date: Sat, 1 Jun 2024 18:10:51 +0200 Subject: [PATCH] upgrade include_dir --- Cargo.lock | 29 ++++++----------------------- Cargo.toml | 2 +- lapce-app/src/config/svg.rs | 4 ++-- lapce-core/src/language.rs | 2 +- 4 files changed, 10 insertions(+), 27 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 3308805f..65f7796e 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2200,12 +2200,6 @@ dependencies = [ "xml-rs", ] -[[package]] -name = "glob" -version = "0.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b919933a397b79c37e33b77bb2aa3dc8eb6e165ad809e58ff75bc7db2e34574" - [[package]] name = "globset" version = "0.4.14" @@ -2628,26 +2622,21 @@ checksum = "029d73f573d8e8d63e6d5020011d3255b28c3ba85d6cf870a07184ed23de9284" [[package]] name = "include_dir" -version = "0.6.2" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24b56e147e6187d61e9d0f039f10e070d0c0a887e24fe0bb9ca3f29bfde62cab" +checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" dependencies = [ - "glob", - "include_dir_impl", - "proc-macro-hack", + "include_dir_macros", ] [[package]] -name = "include_dir_impl" -version = "0.6.2" +name = "include_dir_macros" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0a0c890c85da4bab7bce4204c707396bbd3c6c8a681716a51c8814cfc2b682df" +checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" dependencies = [ - "anyhow", - "proc-macro-hack", "proc-macro2", "quote", - "syn 1.0.109", ] [[package]] @@ -4023,12 +4012,6 @@ dependencies = [ "toml_edit 0.19.15", ] -[[package]] -name = "proc-macro-hack" -version = "0.5.20+deprecated" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" - [[package]] name = "proc-macro2" version = "1.0.79" diff --git a/Cargo.toml b/Cargo.toml index 7a03620e..d1b296e2 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -41,7 +41,7 @@ flate2 = { version = "1.0" } globset = { version = "0.4.14" } hashbrown = { version = "0.14.5", features = ["serde"] } im = { version = "15.0.0", features = ["serde"] } -include_dir = { version = "0.6.2" } +include_dir = { version = "0.7" } indexmap = { version = "2.0", features = ["serde"] } interprocess = { version = "1.2.1" } itertools = { version = "0.12.1" } diff --git a/lapce-app/src/config/svg.rs b/lapce-app/src/config/svg.rs index 93bfb360..800541ea 100644 --- a/lapce-app/src/config/svg.rs +++ b/lapce-app/src/config/svg.rs @@ -8,8 +8,8 @@ use crate::config::LOGO; -const CODICONS_ICONS_DIR: Dir = include_dir!("../icons/codicons"); -const LAPCE_ICONS_DIR: Dir = include_dir!("../icons/lapce"); +const CODICONS_ICONS_DIR: Dir = include_dir!("$CARGO_MANIFEST_DIR/../icons/codicons"); +const LAPCE_ICONS_DIR: Dir = include_dir!("$CARGO_MANIFEST_DIR/../icons/lapce"); #[derive(Debug, Clone)] pub struct SvgStore { diff --git a/lapce-core/src/language.rs b/lapce-core/src/language.rs index b7e4adf8..eae61340 100644 --- a/lapce-core/src/language.rs +++ b/lapce-core/src/language.rs @@ -21,7 +21,7 @@ const DEFAULT_CODE_LENS_LIST: &[&str] = &["source_file"]; #[allow(dead_code)] const DEFAULT_CODE_LENS_IGNORE_LIST: &[&str] = &["source_file"]; -const DEFAULT_QUERIES: include_dir::Dir = include_dir::include_dir!("queries"); +const DEFAULT_QUERIES: include_dir::Dir = include_dir::include_dir!("$CARGO_MANIFEST_DIR/queries"); #[macro_export] macro_rules! comment_properties {