🎈 A cross-platform Discord Rich Presence integration for mpv with no external dependencies.
834116350884577280
)options.active
; options.active
now only controls whether to start the presence on launchD
, can be configured in discord.conf
) to toggle Discord Rich Presence on and offmp.command_native_async()
instead of io.popen()
to launch the subprocess.
This function allows more control of the subprocess i.e. terminating it by calling mp.abort_async_command()
.
It also has a mechanism that terminates the subprocess when mpv shuts down. This can avoid hanging the process when mpv is trying to quit. For more information, see https://mpv.io/manual/stable/#asynchronous-command-details.input-ipc-server
is now made configurable
Uses a static path that defaults to the /tmp/mpvsocket
. The path can be set by the socket_path
option in the config file.
The path can also be dynamic if the use_static_socket_path
option is set to 'yes' in the config file. The filename of the dynamic path will be in the format of mpv-discord-1234
where 1234
is the PID of the mpv instance. Then, the socket_path
option will be used as the directory prefix of the path (defaults to /tmp/
).portable_config
directory when installing on Windows$MPV_HOME
variable when installing on Linux and Darwin (OSX)XX:XX:XX left
) when media is pausedlooping
when the state is actually playing
)