[GH-ISSUE #46] Implement a configuration file (e.g. for keybindings, etc.) #32

Closed
opened 2026-02-28 14:46:30 +03:00 by kerem · 2 comments
Owner

Originally created by @jfaltis on GitHub (Oct 11, 2019).
Original GitHub issue: https://github.com/Rigellute/spotify-tui/issues/46

Create a config for easy customization of keybindings, program behaviour, etc. It could be located at $HOME/.config/spotify-tui/config.yml.

The current client configurations could be moved into this configuration too.
E.g

---
client:
  - client_id:
  - client_secret:
  - device_id:
  
keybindings:
  - left: h
  - down: j
  - up: k
  - right: l
Originally created by @jfaltis on GitHub (Oct 11, 2019). Original GitHub issue: https://github.com/Rigellute/spotify-tui/issues/46 Create a config for easy customization of keybindings, program behaviour, etc. It could be located at `$HOME/.config/spotify-tui/config.yml.` The current client configurations could be moved into this configuration too. E.g ``` --- client: - client_id: - client_secret: - device_id: keybindings: - left: h - down: j - up: k - right: l ```
kerem closed this issue 2026-02-28 14:46:30 +03:00
Author
Owner

@Rigellute commented on GitHub (Oct 15, 2019):

This could be an interesting one.

Are there any bindings that don't currently work for you?

<!-- gh-comment-id:542082625 --> @Rigellute commented on GitHub (Oct 15, 2019): This could be an interesting one. Are there any bindings that don't currently work for you?
Author
Owner

@jfaltis commented on GitHub (Oct 15, 2019):

I think the current bindings are very nice and appeal to the majority of users. But there are also users who might have other preferences (as you could see about the bindings for playback control https://github.com/Rigellute/spotify-tui/issues/16). Having a config for keybindings would be a nice addition for users who are into customizing everything as much as they can.

My suggestion would be that the default settings/bindings (which satisfy the most users) stay in the source code and the config which is being read can overwrite certain bindings. That way the config file doesn't contain all bindings but only the ones users want to change.

Currently I would not merge the client settings into the config yet and get rid of the client.yml. I think it would be nice if you could set these in the config.yml but the client.yml should stay to make it less of a hassle for users who sync their dotfiles with other computers. This is stuff for a later PR anyways.

I think I would rename src/config.rs to src/client_config.rs and add a src/app_config.rs for keybindings and preferences (etc.).

What do you think?

<!-- gh-comment-id:542371184 --> @jfaltis commented on GitHub (Oct 15, 2019): I think the current bindings are very nice and appeal to the majority of users. But there are also users who might have other preferences (as you could see about the bindings for playback control https://github.com/Rigellute/spotify-tui/issues/16). Having a config for keybindings would be a nice addition for users who are into customizing everything as much as they can. My suggestion would be that the default settings/bindings (which satisfy the most users) stay in the source code and the config which is being read can overwrite certain bindings. That way the config file doesn't contain all bindings but only the ones users want to change. Currently I would not merge the client settings into the config yet and get rid of the client.yml. I think it would be nice if you could set these in the config.yml but the client.yml should stay to make it less of a hassle for users who sync their dotfiles with other computers. This is stuff for a later PR anyways. I think I would rename `src/config.rs` to `src/client_config.rs` and add a `src/app_config.rs` for keybindings and preferences (etc.). What do you think?
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-tui#32
No description provided.