Skip to content

Commit

Permalink
Merge pull request #447 from joshuamegnauth54/switch-to-dotenvy
Browse files Browse the repository at this point in the history
  • Loading branch information
ramsayleung authored Nov 21, 2023
2 parents a3bd1c8 + 61e3689 commit a53a7db
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
## 0.12.1 (Unreleased)
**Bugfixes**
- ([#440](https://github.com/ramsayleung/rspotify/issues/440)) Add Smartwatch device type, fix for json parse error: unknown variant Smartwatch.
- ([#447](https://github.com/ramsayleung/rspotify/pull/447)) Replace the deprecated `dotenv` crate with `dotenvy`

## 0.12.0 (2023.08.26)
**New features**
Expand Down
6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ async-stream = { version = "0.3.2", optional = true }
async-trait = { version = "0.1.51", optional = true }
base64 = "0.21.2"
chrono = { version = "0.4.19", features = ["serde"] }
dotenv = { version = "0.15.0", optional = true }
dotenvy = { version = "0.15.0", optional = true }
futures = { version = "0.3.17", optional = true }
getrandom = "0.2.3"
log = "0.4.14"
Expand All @@ -56,7 +56,7 @@ default = ["client-reqwest", "reqwest-default-tls"]

### Client ###
cli = ["webbrowser"]
env-file = ["dotenv"]
env-file = ["dotenvy"]

### HTTP ###
# Available clients. By default they don't include a TLS so that it can be
Expand All @@ -80,7 +80,7 @@ __sync = ["maybe-async/is_sync"]

[package.metadata.docs.rs]
# When generating the docs, we also want to include the CLI methods, and working
# links for `dotenv`. We generate them for ureq so that the function signatures
# links for `dotenvy`. We generate them for ureq so that the function signatures
# of the endpoints don't look gnarly (because of `async-trait`).
features = ["cli", "env-file", "client-ureq"]
no-default-features = true
Expand Down
6 changes: 3 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
//!
//! ### Environmental variables
//!
//! RSpotify supports the `dotenv` crate, which allows you to save credentials
//! RSpotify supports the `dotenvy` crate, which allows you to save credentials
//! in a `.env` file. These will then be automatically available as
//! environmental values when using methods like [`Credentials::from_env`].
//!
Expand Down Expand Up @@ -367,7 +367,7 @@ impl Credentials {
pub fn from_env() -> Option<Self> {
#[cfg(feature = "env-file")]
{
dotenv::dotenv().ok();
dotenvy::dotenv().ok();
}

Some(Self {
Expand Down Expand Up @@ -422,7 +422,7 @@ impl OAuth {
pub fn from_env(scopes: HashSet<String>) -> Option<Self> {
#[cfg(feature = "env-file")]
{
dotenv::dotenv().ok();
dotenvy::dotenv().ok();
}

Some(Self {
Expand Down

0 comments on commit a53a7db

Please sign in to comment.