Skip to content

Conversation

@Vvamp
Copy link

@Vvamp Vvamp commented Apr 15, 2025

Type of change

  • Bug fix
  • Feature
  • Documentation update

Description

Celluloid is a popular MPV frontend. Since celluloid can pass mpv arguments by using a 'mpv-' prefix in the command args, I figured it'd be easy to add. It just uses mpv on the backend after all.

I opted for not adding a new case in the switch, but instead adding the "celluloid" pattern in the mpv option. I then added an optional prefix, which is set if the player is celluloid. It could be done as a seperate option, but I wanted to prevent duplicate code.

I bumped the version to 4.10.0 as I noticed that is what you guys were aiming for in the next release. I checked 'range selection' as working, as you guys are already aware of the pre-existing bug with range selection and it's not related to this PR. The readme and help still mention that --skip only works with mpv, but since celluloid is still just mpv, I thought it was still correct.

Note: To make this work the user would have to copy ani-skip's skip.lua to the scripts folder under ~/.config/celluloid/scripts/ instead of ~/.config/mpv/scripts/.

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 works
  • -S select index works
  • -r range selection works
  • --skip ani-skip works
  • --skip-title ani-skip title argument works
  • --no-detach no detach 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

@Vvamp Vvamp requested a review from Derisis13 as a code owner April 15, 2025 23:53
@Derisis13
Copy link
Collaborator

Thanks for the dettailed explanation and thoughtful implementation.
I'd like to see the readme and the manpage updated to reflect the new capability.
Also please iron out that one shellcheck complaint you seem to have missed.

Then I'll test it myself too, and see if it works. Merging may have to wait until 4.10 is merged too, but maybe we can include the feature in the release.

@Vvamp
Copy link
Author

Vvamp commented Apr 17, 2025

Thanks for the quick reply.
I added the capabilities to the README, help and manpage, as well as a small note to the README's ani-skip section to explain how to get ani-skip to work with celluloid. Let me know if you need me to make any other adjustments.

@Vvamp Vvamp force-pushed the feature/celluloid branch from f4a016d to cf48c97 Compare April 17, 2025 13:43
Copy link
Collaborator

@port19x port19x left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good, elegant flag normalisation

Comment on lines +546 to +547
**Note:** To get ani-skip to work under celluloid, copy the `skip.lua` to celluloid's script folder. This is usually `~/.config/celluloid/scripts`. The `skip.lua` file can be found in the root directory of ani-skip's repository if you installed via source, or in mpv's script directory `~/.config/mpv/scripts` if you installed it using the AUR.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't this belong in the ani-skip documentation instead?

@port19x
Copy link
Collaborator

port19x commented Jul 25, 2025

No detach with celluloid is kinda stupid since its a gui program.
--no-detach was meant for in terminal playback

@port19x
Copy link
Collaborator

port19x commented Jul 25, 2025

Note that I removed your manpage notice that --exit-after-play only works with --no-detach, since the flag --exit-after-play internally enables --no-detach anyway

@Derisis13
Copy link
Collaborator

Just a minor warning: some distros (Fedora) like to package celluloid (like mpv) with URL playback disabled. Maybe it'd be worth noting in the readme.

@port19x
Copy link
Collaborator

port19x commented Jul 27, 2025

Just a minor warning: some distros (Fedora) like to package celluloid (like mpv) with URL playback disabled. Maybe it'd be worth noting in the readme.

We should definitely note that down somewhere, or even just make a dummy issue that is easily discoverable so anyone running into the issue can be referred to it

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.

3 participants