Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create control script for plex #1338

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

chicco-carone
Copy link
Contributor

This pull request introduces a new script, plex_bridge.py, which acts as a bridge between Plex and Snapcast. The script connects to a Plex server, monitors the current playback status, and updates Snapcast accordingly. It also handles various control commands and properties updates for the Plex player.

The script can be added as a control script to a snapcast stream and it requires the plex server ip, token and player name to function properly.

This pr also partially solves this issue: #1165

If needed i can add some simple documentation on how to use it but I just wasn't sure where to put it


Pull Request Checklist

  • Contributions must be licensed under the GPL-3.0 License

  • This project loosely follows the Google C++ Style Guide

  • For better compatibility with embedded toolchains, the used C++ standard should be limited to C++17

  • Code should be formatted by running make reformat

  • Branch from the develop branch and ensure it is up to date with the current develop branch before submitting your pull request. If it doesn't merge cleanly with develop, you may be asked to resolve the conflicts. Pull requests to master will be closed.

  • Commits should be as small as possible while ensuring that each commit is correct independently (i.e., each commit should compile and pass tests).

  • Pull requests must not contain compiled sources (already set by the default .gitignore) or binary files

  • Test your changes as thoroughly as possible before you commit them. Preferably, automate your test by unit/integration tests. If tested manually, provide information about the test scope in the PR description (e.g. “Test passed: Upgrade version from 0.42 to 0.42.23.”).

  • Create Work In Progress [WIP] pull requests only if you need clarification or an explicit review before you can continue your work item.

  • If your patch is not getting reviewed or you need a specific person to review it, you can @-reply a reviewer asking for a review in the pull request or a comment, or you can ask for a review by contacting us via email.

  • Post review:

    • If a review requires you to change your commit(s), please test the changes again.
    • Amend the affected commit(s) and force push onto your branch.
    • Set respective comments in your GitHub review to resolved.
    • Create a general PR comment to notify the reviewers that your amendments are ready for another round of review.

Create a plug-in to add track info and controls to the snapserver
@badaix
Copy link
Owner

badaix commented Feb 6, 2025

Thanks, sounds very interesting!
Could you please add a description of how to setup Plex with Snapcast? The best place should be in player_setup.md.
I would really like to test it, but I've never used plex before.

Add instructions to use plexamp and Plex control script.
@chicco-carone
Copy link
Contributor Author

I added in that file the documentation to set up plexamp with and without control script. I've been using this method for about a year without issues (except the control script since I just made it) and it's working pretty reliably

@badaix
Copy link
Owner

badaix commented Feb 12, 2025

Awesome, thanks :)
I will try it out ASAP (latest the upcoming weekend, I hope).

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.

2 participants