Skip to content

Commit

Permalink
config: refactor and replace structopt by clap
Browse files Browse the repository at this point in the history
This greatly refactors and simplifies the config parsing.

Also, it removes the possiblity to specify user and password,
since this has been phased out by Spotify and will be replaced by OAuth.
  • Loading branch information
eladyn committed Dec 30, 2024
1 parent 3bf0879 commit 83f477f
Show file tree
Hide file tree
Showing 7 changed files with 276 additions and 824 deletions.
226 changes: 38 additions & 188 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 1 addition & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,12 +18,10 @@ fern = { version = "0.7.0", features = ["syslog-6"] }
futures = "0.3.15"
gethostname = "0.5.0"
hex = "0.4"
keyring = { version = "3.5", optional = true, features = ["apple-native", "windows-native", "sync-secret-service"] }
libc = "0.2.82"
log = "0.4.6"
serde = { version = "1.0.115", features = ["derive"] }
sha-1 = "0.10"
structopt = "0.3.17"
tokio = {version = "1.26.0", features = ["signal", "rt-multi-thread", "process", "io-std"] }
tokio-stream = "0.1.7"
url = "2.2.2"
Expand All @@ -39,6 +37,7 @@ color-eyre = "0.6"
directories = "5.0.1"
thiserror = "2.0"
time = { version = "0.3.37", default-features = false, features = ["formatting"] }
clap = { version = "4.5.23", features = ["derive"] }

[target."cfg(unix)".dependencies]
daemonize = "0.5"
Expand All @@ -55,7 +54,6 @@ env_logger = "0.11"

[features]
alsa_backend = ["librespot-playback/alsa-backend", "alsa"]
dbus_keyring = ["keyring"]
dbus_mpris = ["dbus", "dbus-tokio", "dbus-crossroads"]
pipe_backend = []
default = ["alsa_backend", "pipe_backend"]
Expand Down
Loading

0 comments on commit 83f477f

Please sign in to comment.