Clippy's `use_self` line ensures that `Self` is used instead of the real
name whenever possible. This makes searching easier and cleans up the
code a bit.
* config / authentication: permit to call external program for getting credentials
You can add into your ncspot/config.toml like this:
```
creds_username = "mylogin"
creds_passeval = "pass my_pass_path_to_spot_password"
```
Or using any password manager who send your password.to stdout.
If a newline is detected it will be automatically removed
* Move credential commands into separate structure
Also add an option for a username command
* Document credential commands
---------
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org>
* fix(backtrace): Fix backtrace logging and stdout
- Add manual implementation for panic that logs backtrace to a file.
- Remove all manual output to stdout.
- Fix new clippy warnings from Rust 1.65.
* Update docs
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org>
* Added track_name_first config option to allow choosing if artists' names should be shown before or after the track name.
* Added active_fields config option, which allows configuration of which columns are visible in Queue/Library view.
This also removes the need for a separate track_name_first and album_column option.
* Fixed README
* Made custom tracklist formatting more flexible.
Updated readme with new instructions.
Reformatted impl member order to match the definitions in traits.rs.
* Added track_name_first config option to allow choosing if artists' names should be shown before or after the track name.
* Added active_fields config option, which allows configuration of which columns are visible in Queue/Library view.
This also removes the need for a separate track_name_first and album_column option.
* Fixed README
* Made custom tracklist formatting more flexible.
Updated readme with new instructions.
Reformatted impl member order to match the definitions in traits.rs.
* Fetch formatting config from library config
Instead of the lazy static mutex
* Moved custom format function to Playable impl as it's a better location to handle both Tracks and Episodes
* Rename from `tracklist_formatting` to `track_format`
Also shorten `format_{left|center|right}` to `{left|center|right}`
Co-authored-by: Henrik Friedrichsen <henrik@affekt.org>
* Added playback_state config option.
It can be used to pre-define a certain playback state for the player.
* Changed playback_state to use enums and removed redundant check for the "Playing" state.
Serializing an empty `Vec<Playable>` causes serde to panic as described
in #485 This commit tells serde not to serialize `queue` if it is an
empty `Vec`.
Before, copies of the configuration were passed over. This change also
causes configuration reloads to affect the entire application and is
easier to maintain but introduces some RwLock overhead.
`directories` create is no longer maintained, and uses
`~/Library/Preferences` on MacOS, but Apple advises against creating
files in `Preferences`.
`platform-dirs` allows to use `~/.config` on MacOS.