Advertisement
Guest User

Untitled

a guest
Nov 21st, 2020
177
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.55 KB | None | 0 0
  1. from plexapi.server import PlexServer
  2. baseurl = 'http://192.168.1.62:32400'
  3. token = 'yourplextoken'
  4. plex = PlexServer(baseurl, token)
  5.  
  6. show_section = plex.library.section('TV Shows')
  7. added = show_section.search(sort='titleSort')
  8.  
  9. # Add all Disney Shows to Disney.
  10. # found here https://www.reddit.com/r/PleX/comments/fauq6q/automatically_add_all_your_disney_films_to_a/
  11. for show in added:
  12.     print('%s (%s)' % (show.title, show.studio))
  13.     if show.studio is None:
  14.         pass
  15.     elif "Disney" in show.studio:
  16.         show.addCollection('Disney')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement