Skip to content

feat: add mpv playlist support#1755

Open
mbpowers wants to merge 1 commit into
pystardust:masterfrom
mbpowers:master
Open

feat: add mpv playlist support#1755
mbpowers wants to merge 1 commit into
pystardust:masterfrom
mbpowers:master

Conversation

@mbpowers

Copy link
Copy Markdown

Pull Request Template

Type of change

  • Bug fix
  • Feature
  • Documentation update

Description

Added an option -p or --playlist which adds episodes to a single mpv instance's playlist instead of spawning a new instance each episode. A new episode is only added to the mpv playlist when you have reached the last playlist entry and you haven't reached the end of the range i.e. get_episode_url will only run as needed to avoid spamming.

I neglected to update the README/Manpage yet because I am wondering about the implications of me adding the dependency socat for listening to the mpv IPC unix socket. Is this dependency justified? I am not familiar with how ani-cli works Windows and it seems like won't support this unix socket approach. In that case using netcat or something for tcp sockets could be best? Or would this be fine as unix only for now? And if no dependencies are justified for this then it could be possibly reworked with fifos and an mpv lua script, but since they block I think that would be more complicated with the current code structure, and that would still be unix only.

Anyways, I wanted to ask before messing with it more as I am happy with where this is at for my own purposes. Let me know if there are any suggestions or required changes

Checklist

  • any anime playing
  • bumped version

  • next, prev and replay work
  • -c history and continue work
  • -d downloads work
  • -s syncplay works
  • -q quality works
  • -v vlc works
  • -e (select episode) aka -r (range selection) works
  • -S select index works
  • --skip ani-skip works
  • --skip-title ani-skip title argument works
  • --no-detach no detach works
  • --exit-after-play auto exit after playing works
  • --nextep-countdown countdown to next ep works
  • --dub and regular (sub) mode both work
  • all providers return links (not necessarily on a single anime, use debug mode to confirm)

  • -h help info is up to date
  • Readme is up to date
  • Man page is up to date

Additional Testcases

  • The safe bet: One Piece
  • Episode 0: Saenai Heroine no Sodatekata ♭
  • Unicode: Saenai Heroine no Sodatekata ♭
  • Non-whole episodes: Tensei shitara slime datta ken (ep. 24.5, ep. 24.9)
  • All Providers: Youkoso Jitsuryoku Shijou Shugi no Kyoushitsu e (TV) (3 m3u8, 3 mp4, 1 fast4speed, 1 sharepoint)
  • The examples of the help text

@mbpowers mbpowers requested a review from Derisis13 as a code owner June 26, 2026 04:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant