[GH-ISSUE #724] Parameterized Seek{Backward,Forward} command (for keymaps) #1364

Closed
opened 2026-03-14 14:32:36 +03:00 by kerem · 2 comments
Owner

Originally created by @sandersantema on GitHub (May 15, 2025).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/724

Is your feature already implemented in the latest master?
Please go through the Features README page to make sure your request feature hasn't been implemented.
No.
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Currently I use the official spotify client together with spicetify and some custom code for their vim like keybindings extension. The custom code allows me to seek forward/ backward by an amount specified by me, that is, I use w and e to seek backwards and forwards by 100secs respectively and W and E to seek backwards and forwards by 20secs respectively. I'd like to be able to do the same in spotify-player. If you're wondering what my use case is: music discovery, I check out a lot of songs and often don't need to hear the whole song to know whether it is worth listening to in detail, quickly skipping through a song and hearing some snippets is enough.

Describe the solution you'd like
I'd like a configurable seek amount, something like:

[[keymaps]]
command = { SeekBackwardBy = { secs = 100 } }
key_sequence = "w"

[[keymaps]]
command = { SeekBackwardBy = { secs = 20 } }
key_sequence = "W"

[[keymaps]]
command = { SeekForwardBy = { secs = 100 } }
key_sequence = "e"

[[keymaps]]
command = { SeekForwardBy = { secs = 20 } }
key_sequence = "E"

Or alternatively just by changing the original Seek{Backward,Forward} commands, but I think both commands are useful as not every body will need a configurable seek amount.

Describe alternatives you've considered
I've considered seeking by a configurable amount using playerctl but that would require support for executing shell commands using keybindings, which isn't supported afaik.

Originally created by @sandersantema on GitHub (May 15, 2025). Original GitHub issue: https://github.com/aome510/spotify-player/issues/724 **Is your feature already implemented in the latest `master`?** Please go through the [Features README page](https://github.com/aome510/spotify-player?tab=readme-ov-file#features) to make sure your request feature hasn't been implemented. No. **Is your feature request related to a problem? Please describe.** A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] Currently I use the official spotify client together with spicetify and some custom code for their vim like keybindings extension. The custom code allows me to seek forward/ backward by an amount specified by me, that is, I use `w` and `e` to seek backwards and forwards by 100secs respectively and `W` and `E` to seek backwards and forwards by 20secs respectively. I'd like to be able to do the same in spotify-player. If you're wondering what my use case is: music discovery, I check out a lot of songs and often don't need to hear the whole song to know whether it is worth listening to in detail, quickly skipping through a song and hearing some snippets is enough. **Describe the solution you'd like** I'd like a configurable seek amount, something like: ```toml [[keymaps]] command = { SeekBackwardBy = { secs = 100 } } key_sequence = "w" [[keymaps]] command = { SeekBackwardBy = { secs = 20 } } key_sequence = "W" [[keymaps]] command = { SeekForwardBy = { secs = 100 } } key_sequence = "e" [[keymaps]] command = { SeekForwardBy = { secs = 20 } } key_sequence = "E" ``` Or alternatively just by changing the original `Seek{Backward,Forward}` commands, but I think both commands are useful as not every body will need a configurable seek amount. **Describe alternatives you've considered** I've considered seeking by a configurable amount using `playerctl` but that would require support for executing shell commands using keybindings, which isn't supported afaik.
kerem 2026-03-14 14:32:36 +03:00
Author
Owner

@Valkyrja-Design commented on GitHub (Aug 5, 2025):

Hi @aome510 , if this is still available can I take this up? I skimmed through the code a bit, do you think it'd be good to modify the SeekForward/SeekBackward enum variants to accept an Option<i32> as the seek duration with None meaning to use AppConfig::seek_duration_secs and the specified duration otherwise?

<!-- gh-comment-id:3156194687 --> @Valkyrja-Design commented on GitHub (Aug 5, 2025): Hi @aome510 , if this is still available can I take this up? I skimmed through the code a bit, do you think it'd be good to modify the `SeekForward`/`SeekBackward` enum variants to accept an `Option<i32>` as the seek duration with `None` meaning to use `AppConfig::seek_duration_secs` and the specified duration otherwise?
Author
Owner

@aome510 commented on GitHub (Aug 5, 2025):

Hi @aome510 , if this is still available can I take this up? I skimmed through the code a bit, do you think it'd be good to modify the SeekForward/SeekBackward enum variants to accept an Option<i32> as the seek duration with None meaning to use AppConfig::seek_duration_secs and the specified duration otherwise?

Yes, feel free to take this. AFAICT, there is no active PR to implement this feature. Your approach sounds good to me!

<!-- gh-comment-id:3156233186 --> @aome510 commented on GitHub (Aug 5, 2025): > Hi [@aome510](https://github.com/aome510) , if this is still available can I take this up? I skimmed through the code a bit, do you think it'd be good to modify the `SeekForward`/`SeekBackward` enum variants to accept an `Option<i32>` as the seek duration with `None` meaning to use `AppConfig::seek_duration_secs` and the specified duration otherwise? Yes, feel free to take this. AFAICT, there is no active PR to implement this feature. Your approach sounds good to me!
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-player#1364
No description provided.