branch: elpa/mpv commit 6cf13615a7e1d12ee138d28340e1832cc85213ee Author: Hitoshi Uchida <uch...@w3.org> Commit: GitHub <nore...@github.com>
Add commands to go to next/prev entry on the playlist (#20) --- README.md | 1 + mpv.el | 12 ++++++++++++ 2 files changed, 13 insertions(+) diff --git a/README.md b/README.md index cecebce604..40f80900e2 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,7 @@ Among others, mpv.el provides - `mpv-volume-increase` / `mpv-speed-volume` - `mpv-insert-playback-position` - `mpv-seek-to-position-at-point` +- `mpv-playlist-next` / `mpv-playlist-prev` Apart from that, just have a look at the interactive functions in [mpv.el](mpv.el) or the [wiki][] for tips on configuration. diff --git a/mpv.el b/mpv.el index 5b9847538e..4dabe16230 100644 --- a/mpv.el +++ b/mpv.el @@ -387,6 +387,18 @@ of \\[universal-argument] will add another `mpv-seek-step' seconds." (interactive) (mpv--enqueue '("revert-seek") #'ignore)) +;;;###autoload +(defun mpv-playlist-next () + "Go to the next entry on the playlist." + (interactive) + (mpv--enqueue '("playlist-next") #'ignore)) + +;;;###autoload +(defun mpv-playlist-prev () + "Go to the previous entry on the playlist." + (interactive) + (mpv--enqueue '("playlist-prev") #'ignore)) + ;;;###autoload (defun mpv-version () "Return the mpv version string.