-
Notifications
You must be signed in to change notification settings - Fork 459
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TOML config #571
TOML config #571
Conversation
sorry I used the github app and the 'close' button hella confused me |
I'll merge this into a WIP branch for the major release this week! Not sure if |
yay! I used serde_repr so both structopt and toml take an integer, otherwise toml would expect a string. But maybe theres another way, for me changing the renames to repr worked. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like it 😀 Are there working configs that will work differently after this PR?
I would imagine not since ini is a subset of toml but any value not a number or boolean now must be in quotes whereas it doesn't matter for ini. edit: I realise my massive contradiction lmao |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@0jdxt the readme now has this line
username = username
should that then become
username = "username"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! So just for clarity, this will be a breaking change.
indeed |
this will help users who may not have used TOML before - link will need to be updated when the toml crate updates to support TOML v1.0
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR! This is a great first step for better UX
@@ -169,27 +169,27 @@ spotifyd --help | |||
|
|||
### Configuration file | |||
|
|||
`Spotifyd` is able to load configuration values from a file too. The file has to be named `spotifyd.conf` and reside in the user's configuration directory (`~/.config/spotifyd`) or the system configuration directory (`/etc` or `/etc/xdg/spotifyd`). This also applies to macOS! | |||
`Spotifyd` is able to load configuration values from a [TOML](https://toml.io/en/v0.5.0) file too. The file has to be named `spotifyd.conf` and reside in the user's configuration directory (`~/.config/spotifyd`) or the system configuration directory (`/etc` or `/etc/xdg/spotifyd`). This also applies to macOS! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now we've made breaking changes, I'd like to use the ``.toml` extension. That doesn't need to be part of this PR though
I had a problem with '#' being in my password and i saw it was an issue with serde_ini and in this milestone so did this. i think it works