From 1050448ebd42338bd008cece24345cd95121daaa Mon Sep 17 00:00:00 2001 From: Leonidas Spyropoulos Date: Tue, 4 Oct 2022 11:02:51 +0100 Subject: [PATCH] chore(deps): replace unmaintained dotenv with dotenvy (#30) Fixes: #25 Signed-off-by: Leonidas Spyropoulos 3 --- Cargo.lock | 62 +++++++++++++++++++++++++++++++++++++++++++++++++---- Cargo.toml | 2 +- src/main.rs | 2 +- 3 files changed, 60 insertions(+), 6 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index f187f23..2df0bfb 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -543,10 +543,33 @@ dependencies = [ ] [[package]] -name = "dotenv" -version = "0.15.0" +name = "dirs" +version = "4.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77c90badedccf4105eca100756a0b1289e191f6fcbdadd3cee1d2f614f97da8f" +checksum = "ca3aa72a6f96ea37bbc5aa912f6788242832f75369bdfdadcb0e38423f100059" +dependencies = [ + "dirs-sys", +] + +[[package]] +name = "dirs-sys" +version = "0.3.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1b1d1d91c932ef41c0f2663aa8b0ca0342d444d842c06914aa0a7e352d0bada6" +dependencies = [ + "libc", + "redox_users", + "winapi 0.3.9", +] + +[[package]] +name = "dotenvy" +version = "0.15.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed9155c8f4dc55c7470ae9da3f63c6785245093b3f6aeb0f5bf2e968efbba314" +dependencies = [ + "dirs", +] [[package]] name = "either" @@ -1312,6 +1335,17 @@ dependencies = [ "bitflags", ] +[[package]] +name = "redox_users" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" +dependencies = [ + "getrandom", + "redox_syscall", + "thiserror", +] + [[package]] name = "regex" version = "1.6.0" @@ -1376,7 +1410,7 @@ dependencies = [ "awc", "byte-unit", "config", - "dotenv", + "dotenvy", "env_logger", "futures-util", "glob", @@ -1590,6 +1624,26 @@ dependencies = [ "unicode-width", ] +[[package]] +name = "thiserror" +version = "1.0.37" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "10deb33631e3c9018b9baf9dcbbc4f737320d2b576bac10f6aefa048fa407e3e" +dependencies = [ + "thiserror-impl", +] + +[[package]] +name = "thiserror-impl" +version = "1.0.37" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "982d17546b47146b28f7c22e3d08465f6b8903d0ea13c1660d9d84a6e7adcdbb" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "time" version = "0.3.14" diff --git a/Cargo.toml b/Cargo.toml index 21a4686..19ab36c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -23,7 +23,7 @@ serde = "1.0.145" futures-util = "0.3.24" petname = "1.1.2" rand = "0.8.5" -dotenv = "0.15.0" +dotenvy = "0.15.5" url = "2.3.1" mime = "0.3.16" regex = "1.6.0" diff --git a/src/main.rs b/src/main.rs index 025ec8f..badcf04 100644 --- a/src/main.rs +++ b/src/main.rs @@ -19,7 +19,7 @@ use std::time::Duration; #[actix_web::main] async fn main() -> IoResult<()> { // Load the .env file. - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); // Initialize logger. env_logger::init_from_env(env_logger::Env::new().default_filter_or("info"));