From d9ac2f150913a9314bfe13978629b4df1388af20 Mon Sep 17 00:00:00 2001 From: Horu <73709188+HigherOrderLogic@users.noreply.github.com> Date: Wed, 5 Oct 2022 22:19:48 +0700 Subject: [PATCH] fix(deps): dotenv -> dotenvy (#1085) --- examples/actix3_example/api/Cargo.toml | 2 +- examples/actix3_example/api/src/lib.rs | 2 +- examples/actix_example/api/Cargo.toml | 2 +- examples/actix_example/api/src/lib.rs | 2 +- examples/axum_example/api/Cargo.toml | 2 +- examples/axum_example/api/src/lib.rs | 2 +- examples/graphql_example/api/Cargo.toml | 2 +- examples/graphql_example/api/src/lib.rs | 2 +- examples/graphql_example/migration/Cargo.toml | 2 +- examples/graphql_example/migration/src/main.rs | 2 +- examples/jsonrpsee_example/api/Cargo.toml | 2 +- examples/jsonrpsee_example/api/src/lib.rs | 2 +- examples/poem_example/api/Cargo.toml | 2 +- examples/poem_example/api/src/lib.rs | 2 +- examples/salvo_example/api/Cargo.toml | 2 +- examples/salvo_example/api/src/lib.rs | 2 +- issues/471/Cargo.toml | 2 +- issues/471/src/main.rs | 2 +- issues/693/Cargo.toml | 2 +- sea-orm-cli/Cargo.toml | 2 +- sea-orm-cli/src/bin/main.rs | 2 +- sea-orm-cli/src/bin/sea.rs | 2 +- sea-orm-migration/Cargo.toml | 2 +- sea-orm-migration/src/cli.rs | 2 +- 24 files changed, 24 insertions(+), 24 deletions(-) diff --git a/examples/actix3_example/api/Cargo.toml b/examples/actix3_example/api/Cargo.toml index 5f38712e0..16160b491 100644 --- a/examples/actix3_example/api/Cargo.toml +++ b/examples/actix3_example/api/Cargo.toml @@ -14,7 +14,7 @@ actix-files = "0.5" futures = { version = "^0.3" } futures-util = { version = "^0.3" } tera = "1.8.0" -dotenv = "0.15" +dotenvy = "0.15" listenfd = "0.3.3" serde = "1" tracing-subscriber = { version = "0.3", features = ["env-filter"] } diff --git a/examples/actix3_example/api/src/lib.rs b/examples/actix3_example/api/src/lib.rs index 275e4a7cc..e35d88d2d 100644 --- a/examples/actix3_example/api/src/lib.rs +++ b/examples/actix3_example/api/src/lib.rs @@ -168,7 +168,7 @@ async fn start() -> std::io::Result<()> { tracing_subscriber::fmt::init(); // get env vars - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let host = env::var("HOST").expect("HOST is not set in .env file"); let port = env::var("PORT").expect("PORT is not set in .env file"); diff --git a/examples/actix_example/api/Cargo.toml b/examples/actix_example/api/Cargo.toml index 078e5561a..4a6727e96 100644 --- a/examples/actix_example/api/Cargo.toml +++ b/examples/actix_example/api/Cargo.toml @@ -13,7 +13,7 @@ actix-rt = "2.7" actix-service = "2" actix-web = "4" tera = "1.15.0" -dotenv = "0.15" +dotenvy = "0.15" listenfd = "0.5" serde = "1" tracing-subscriber = { version = "0.3", features = ["env-filter"] } diff --git a/examples/actix_example/api/src/lib.rs b/examples/actix_example/api/src/lib.rs index f95200e84..64a909a94 100644 --- a/examples/actix_example/api/src/lib.rs +++ b/examples/actix_example/api/src/lib.rs @@ -160,7 +160,7 @@ async fn start() -> std::io::Result<()> { tracing_subscriber::fmt::init(); // get env vars - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let host = env::var("HOST").expect("HOST is not set in .env file"); let port = env::var("PORT").expect("PORT is not set in .env file"); diff --git a/examples/axum_example/api/Cargo.toml b/examples/axum_example/api/Cargo.toml index dc1f5ce49..caa1cb8c5 100644 --- a/examples/axum_example/api/Cargo.toml +++ b/examples/axum_example/api/Cargo.toml @@ -13,7 +13,7 @@ tower = "0.4.12" tower-http = { version = "0.3.3", features = ["fs"] } tower-cookies = "0.6.0" anyhow = "1.0.57" -dotenv = "0.15.0" +dotenvy = "0.15.0" serde = "1.0.137" serde_json = "1.0.81" tera = "1.15.0" diff --git a/examples/axum_example/api/src/lib.rs b/examples/axum_example/api/src/lib.rs index ead63e7b1..edeee6619 100644 --- a/examples/axum_example/api/src/lib.rs +++ b/examples/axum_example/api/src/lib.rs @@ -27,7 +27,7 @@ async fn start() -> anyhow::Result<()> { env::set_var("RUST_LOG", "debug"); tracing_subscriber::fmt::init(); - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let host = env::var("HOST").expect("HOST is not set in .env file"); let port = env::var("PORT").expect("PORT is not set in .env file"); diff --git a/examples/graphql_example/api/Cargo.toml b/examples/graphql_example/api/Cargo.toml index e4526410b..a4fd78f44 100644 --- a/examples/graphql_example/api/Cargo.toml +++ b/examples/graphql_example/api/Cargo.toml @@ -9,7 +9,7 @@ publish = false graphql-example-core = { path = "../core" } tokio = { version = "1.0", features = ["full"] } axum = "^0.5.1" -dotenv = "0.15.0" +dotenvy = "0.15.0" async-graphql-axum = "^4.0.6" entity = { path = "../entity" } migration = { path = "../migration" } diff --git a/examples/graphql_example/api/src/lib.rs b/examples/graphql_example/api/src/lib.rs index 42e63e1cf..85275fcbe 100644 --- a/examples/graphql_example/api/src/lib.rs +++ b/examples/graphql_example/api/src/lib.rs @@ -14,7 +14,7 @@ use axum::{ use graphql::schema::{build_schema, AppSchema}; #[cfg(debug_assertions)] -use dotenv::dotenv; +use dotenvy::dotenv; async fn graphql_handler(schema: Extension, req: GraphQLRequest) -> GraphQLResponse { schema.execute(req.into_inner()).await.into() diff --git a/examples/graphql_example/migration/Cargo.toml b/examples/graphql_example/migration/Cargo.toml index 4d42e6214..f63e03ba6 100644 --- a/examples/graphql_example/migration/Cargo.toml +++ b/examples/graphql_example/migration/Cargo.toml @@ -9,7 +9,7 @@ name = "migration" path = "src/lib.rs" [dependencies] -dotenv = "0.15.0" +dotenvy = "0.15.0" async-std = { version = "^1", features = ["attributes", "tokio1"] } [dependencies.sea-orm-migration] diff --git a/examples/graphql_example/migration/src/main.rs b/examples/graphql_example/migration/src/main.rs index 37517f250..8678e0ad0 100644 --- a/examples/graphql_example/migration/src/main.rs +++ b/examples/graphql_example/migration/src/main.rs @@ -1,7 +1,7 @@ use sea_orm_migration::prelude::*; #[cfg(debug_assertions)] -use dotenv::dotenv; +use dotenvy::dotenv; #[async_std::main] async fn main() { diff --git a/examples/jsonrpsee_example/api/Cargo.toml b/examples/jsonrpsee_example/api/Cargo.toml index 51c959e6a..7f84ecd3e 100644 --- a/examples/jsonrpsee_example/api/Cargo.toml +++ b/examples/jsonrpsee_example/api/Cargo.toml @@ -10,7 +10,7 @@ jsonrpsee = { version = "^0.8.0", features = ["full"] } jsonrpsee-core = "0.9.0" tokio = { version = "1.8.0", features = ["full"] } serde = { version = "1", features = ["derive"] } -dotenv = "0.15" +dotenvy = "0.15" entity = { path = "../entity" } migration = { path = "../migration" } anyhow = "1.0.52" diff --git a/examples/jsonrpsee_example/api/src/lib.rs b/examples/jsonrpsee_example/api/src/lib.rs index f98cc1832..584c50651 100644 --- a/examples/jsonrpsee_example/api/src/lib.rs +++ b/examples/jsonrpsee_example/api/src/lib.rs @@ -102,7 +102,7 @@ async fn start() -> std::io::Result<()> { ); // get env vars - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let host = env::var("HOST").expect("HOST is not set in .env file"); let port = env::var("PORT").expect("PORT is not set in .env file"); diff --git a/examples/poem_example/api/Cargo.toml b/examples/poem_example/api/Cargo.toml index 379bc1815..002117498 100644 --- a/examples/poem_example/api/Cargo.toml +++ b/examples/poem_example/api/Cargo.toml @@ -10,6 +10,6 @@ poem = { version = "1.2.33", features = ["static-files"] } tracing-subscriber = { version = "0.3", features = ["env-filter"] } serde = { version = "1", features = ["derive"] } tera = "1.8.0" -dotenv = "0.15" +dotenvy = "0.15" entity = { path = "../entity" } migration = { path = "../migration" } diff --git a/examples/poem_example/api/src/lib.rs b/examples/poem_example/api/src/lib.rs index 3dc8fb037..34eacdcd0 100644 --- a/examples/poem_example/api/src/lib.rs +++ b/examples/poem_example/api/src/lib.rs @@ -126,7 +126,7 @@ async fn start() -> std::io::Result<()> { tracing_subscriber::fmt::init(); // get env vars - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let host = env::var("HOST").expect("HOST is not set in .env file"); let port = env::var("PORT").expect("PORT is not set in .env file"); diff --git a/examples/salvo_example/api/Cargo.toml b/examples/salvo_example/api/Cargo.toml index cc26a7746..6f3296250 100644 --- a/examples/salvo_example/api/Cargo.toml +++ b/examples/salvo_example/api/Cargo.toml @@ -10,6 +10,6 @@ salvo = { version = "0.27", features = ["affix", "serve-static"] } tracing-subscriber = { version = "0.3", features = ["env-filter"] } serde = { version = "1", features = ["derive"] } tera = "1.8.0" -dotenv = "0.15" +dotenvy = "0.15" entity = { path = "../entity" } migration = { path = "../migration" } diff --git a/examples/salvo_example/api/src/lib.rs b/examples/salvo_example/api/src/lib.rs index 225080552..70a74e316 100644 --- a/examples/salvo_example/api/src/lib.rs +++ b/examples/salvo_example/api/src/lib.rs @@ -148,7 +148,7 @@ pub async fn main() { tracing_subscriber::fmt::init(); // get env vars - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let host = env::var("HOST").expect("HOST is not set in .env file"); let port = env::var("PORT").expect("PORT is not set in .env file"); diff --git a/issues/471/Cargo.toml b/issues/471/Cargo.toml index dffc14c6d..5640366f5 100644 --- a/issues/471/Cargo.toml +++ b/issues/471/Cargo.toml @@ -11,7 +11,7 @@ publish = false [dependencies] tokio = { version = "1.14", features = ["full"] } anyhow = "1" -dotenv = "0.15" +dotenvy = "0.15" futures-util = "0.3" serde = "1" tracing-subscriber = { version = "0.3", features = ["env-filter"] } diff --git a/issues/471/src/main.rs b/issues/471/src/main.rs index 9d7f664dd..d4e93a950 100644 --- a/issues/471/src/main.rs +++ b/issues/471/src/main.rs @@ -11,7 +11,7 @@ async fn main() -> anyhow::Result<()> { env::set_var("RUST_LOG", "debug"); tracing_subscriber::fmt::init(); - dotenv::dotenv().ok(); + dotenvy::dotenv().ok(); let db_url = env::var("DATABASE_URL").expect("DATABASE_URL is not set in .env file"); let db = Database::connect(db_url) .await diff --git a/issues/693/Cargo.toml b/issues/693/Cargo.toml index acd1bb0e6..8ec2caeed 100644 --- a/issues/693/Cargo.toml +++ b/issues/693/Cargo.toml @@ -11,7 +11,7 @@ publish = false [dependencies] tokio = { version = "1.14", features = ["full"] } anyhow = "1" -dotenv = "0.15" +dotenvy = "0.15" futures-util = "0.3" serde = "1" tracing-subscriber = { version = "0.3", features = ["env-filter"] } diff --git a/sea-orm-cli/Cargo.toml b/sea-orm-cli/Cargo.toml index f1e26a564..3885e5a18 100644 --- a/sea-orm-cli/Cargo.toml +++ b/sea-orm-cli/Cargo.toml @@ -32,7 +32,7 @@ required-features = ["codegen"] [dependencies] clap = { version = "^3.2", features = ["env", "derive"] } -dotenv = { version = "^0.15" } +dotenvy = { version = "^0.15" } async-std = { version = "^1.9", features = [ "attributes", "tokio1" ] } sea-orm-codegen = { version = "^0.10.0", path = "../sea-orm-codegen", optional = true } sea-schema = { version = "^0.9.3" } diff --git a/sea-orm-cli/src/bin/main.rs b/sea-orm-cli/src/bin/main.rs index ce41c6162..e9d40401c 100644 --- a/sea-orm-cli/src/bin/main.rs +++ b/sea-orm-cli/src/bin/main.rs @@ -1,5 +1,5 @@ use clap::StructOpt; -use dotenv::dotenv; +use dotenvy::dotenv; use sea_orm_cli::{handle_error, run_generate_command, run_migrate_command, Cli, Commands}; #[async_std::main] diff --git a/sea-orm-cli/src/bin/sea.rs b/sea-orm-cli/src/bin/sea.rs index cc945f95f..4a8b3d140 100644 --- a/sea-orm-cli/src/bin/sea.rs +++ b/sea-orm-cli/src/bin/sea.rs @@ -1,7 +1,7 @@ //! COPY FROM bin/main.rs use clap::StructOpt; -use dotenv::dotenv; +use dotenvy::dotenv; use sea_orm_cli::{handle_error, run_generate_command, run_migrate_command, Cli, Commands}; #[async_std::main] diff --git a/sea-orm-migration/Cargo.toml b/sea-orm-migration/Cargo.toml index 2e3585022..4abed0401 100644 --- a/sea-orm-migration/Cargo.toml +++ b/sea-orm-migration/Cargo.toml @@ -22,7 +22,7 @@ path = "src/lib.rs" [dependencies] async-trait = { version = "^0.1" } clap = { version = "^3.2", features = ["env", "derive"] } -dotenv = { version = "^0.15" } +dotenvy = { version = "^0.15" } sea-orm = { version = "^0.10.0", path = "../", default-features = false, features = ["macros"] } sea-orm-cli = { version = "^0.10.0", path = "../sea-orm-cli", default-features = false } sea-schema = { version = "^0.9.3" } diff --git a/sea-orm-migration/src/cli.rs b/sea-orm-migration/src/cli.rs index de228c406..d098cb818 100644 --- a/sea-orm-migration/src/cli.rs +++ b/sea-orm-migration/src/cli.rs @@ -1,5 +1,5 @@ use clap::Parser; -use dotenv::dotenv; +use dotenvy::dotenv; use std::{error::Error, fmt::Display, process::exit}; use tracing_subscriber::{prelude::*, EnvFilter};