From 2751831a755323ba722c4fedea0ba269a82b6718 Mon Sep 17 00:00:00 2001 From: Boog900 <54e72d8a-345f-4599-bd90-c6b9bc7d0ec5@aleeas.com> Date: Sat, 26 Oct 2024 23:35:11 +0100 Subject: [PATCH] try fix windows --- binaries/cuprated/src/config/Cuprate.toml | 3 +++ binaries/cuprated/src/config/default.rs | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/binaries/cuprated/src/config/Cuprate.toml b/binaries/cuprated/src/config/Cuprate.toml index aa8031f..66cc43c 100644 --- a/binaries/cuprated/src/config/Cuprate.toml +++ b/binaries/cuprated/src/config/Cuprate.toml @@ -1,3 +1,4 @@ +r#" # ____ _ # / ___| _ _ __ _ __ __ _| |_ ___ # | | | | | | '_ \| '__/ _` | __/ _ \ @@ -73,3 +74,5 @@ max_txpool_size = 100_000_000 path = "{blockchain}" ## The database sync mode for the blockchain. sync_mode = "Async" + +"# \ No newline at end of file diff --git a/binaries/cuprated/src/config/default.rs b/binaries/cuprated/src/config/default.rs index d1438c8..87e78bd 100644 --- a/binaries/cuprated/src/config/default.rs +++ b/binaries/cuprated/src/config/default.rs @@ -1,6 +1,7 @@ use std::{ io::Write, path::{Path, PathBuf}, + str::from_utf8, }; use cuprate_helper::fs::{CUPRATE_BLOCKCHAIN_DIR, CUPRATE_CACHE_DIR, CUPRATE_TXPOOL_DIR}; @@ -36,7 +37,7 @@ pub fn create_default_config_file(path: &Path) -> ! { /// Generates the text of the default config file. fn generate_config_text() -> String { format!( - include_str!("Cuprate.toml"), + include!("Cuprate.toml"), cache = CUPRATE_CACHE_DIR.to_string_lossy(), txpool = CUPRATE_TXPOOL_DIR.to_string_lossy(), blockchain = CUPRATE_BLOCKCHAIN_DIR.to_string_lossy()