mirror of
https://github.com/FakeTV/pseudo-channel.git
synced 2026-01-16 15:03:16 +00:00
Added variable in config to specify the html title.
This commit is contained in:
@@ -50,6 +50,7 @@ class PseudoChannel():
|
||||
DEBUG = config.debug_mode
|
||||
ROTATE_LOG = config.rotateLog
|
||||
USE_DIRTY_GAP_FIX = config.useDirtyGapFix
|
||||
HTML_PSEUDO_TITLE = config.htmlPseudoTitle
|
||||
|
||||
def __init__(self):
|
||||
|
||||
@@ -61,7 +62,8 @@ class PseudoChannel():
|
||||
config.plexClients,
|
||||
self.CONTROLLER_SERVER_PATH,
|
||||
self.CONTROLLER_SERVER_PORT,
|
||||
self.DEBUG
|
||||
self.DEBUG,
|
||||
self.HTML_PSEUDO_TITLE
|
||||
)
|
||||
|
||||
self.movieMagic = PseudoChannelRandomMovie()
|
||||
|
||||
@@ -97,20 +97,20 @@ Whenever you add new content to your Plex library, you need to run: `python Pseu
|
||||
|
||||
## Multi-Channel Support:
|
||||
|
||||
You can have multpile instances of this app, specify different schedules for each instance and control it via a USB remote. Let's say you choose to have 3 channels, an all day movie channel, a 'cartoon network' channel, and a 90's channel. You would simply create a directory named something like `/channels`. Then within your `/channels` dir you would have your `plex_token.py` file and your channels named something like: `/channel_1`, `channel_2` & `channel_3`. Note: the only important naming convention here is that `_1`, `_2`, etc. is contained at the end of each directory title. Each channel directory will contain the contents of this repository, set up just as if you had a single channel. So your directory structure would look like this:
|
||||
You can have multpile instances of this app, specify different schedules for each instance and control it via a USB remote. Let's say you choose to have 3 channels, an all day movie channel, a 'cartoon network' channel, and a 90's channel. You would simply create a directory named something like `/channels`. Then within your `/channels` dir you would have your `plex_token.py` file and your channels named something like: `/channel_1`, `channel_2` & `channel_3`. Note: the only important naming convention here is that `_01`, `_02`, etc. is contained at the end of each directory title. Each channel directory will contain the contents of this repository, set up just as if you had a single channel. So your directory structure would look like this:
|
||||
|
||||
```bash
|
||||
-channels/
|
||||
--plex_token.py
|
||||
--channel_1/
|
||||
--channel_01/
|
||||
---pseudo-channel.db
|
||||
---PseudoChannel.py
|
||||
---...etc.
|
||||
--channel_2/
|
||||
--channel_02/
|
||||
---pseudo-channel.db
|
||||
---PseudoChannel.py
|
||||
---...etc.
|
||||
--channel_3/
|
||||
--channel_03/
|
||||
---pseudo-channel.db
|
||||
---PseudoChannel.py
|
||||
---...etc.
|
||||
|
||||
@@ -14,15 +14,15 @@ All of these scripts need to be placed in the "./channels/" dir. Your directory
|
||||
```bash
|
||||
-channels/
|
||||
--plex_token.py
|
||||
--channel_1/
|
||||
--channel_01/
|
||||
---pseudo-channel.db
|
||||
---PseudoChannel.py
|
||||
---...etc.
|
||||
--channel_2/
|
||||
--channel_02/
|
||||
---pseudo-channel.db
|
||||
---PseudoChannel.py
|
||||
---...etc.
|
||||
--channel_3/
|
||||
--channel_03/
|
||||
---pseudo-channel.db
|
||||
---PseudoChannel.py
|
||||
---...etc.
|
||||
|
||||
@@ -61,6 +61,11 @@ You can also leave the below controllerServerPath empty if you'd like to run you
|
||||
controllerServerPath = "http://192.168.1.28"
|
||||
controllerServerPort = "8000"
|
||||
|
||||
"""
|
||||
This variable sets the title for the PseudoChannel.py html page.
|
||||
"""
|
||||
htmlPseudoTitle = "Daily PseudoChannel"
|
||||
|
||||
"""
|
||||
When the schedule updates every 24 hours, it's possible that it will interrupt any shows / movies that were
|
||||
playing from the previous day. To fix this, the app saves a "cached" schedule from the previous day to
|
||||
|
||||
@@ -19,7 +19,8 @@ class PseudoDailyScheduleController():
|
||||
clients,
|
||||
controllerServerPath = '',
|
||||
controllerServerPort = '8000',
|
||||
debugMode = False
|
||||
debugMode = False,
|
||||
htmlPseudoTitle = "Daily PseudoChannel"
|
||||
):
|
||||
|
||||
self.PLEX = PlexServer(server, token)
|
||||
@@ -30,6 +31,7 @@ class PseudoDailyScheduleController():
|
||||
self.CONTROLLER_SERVER_PORT = controllerServerPort if controllerServerPort != '' else '80'
|
||||
self.DEBUG = debugMode
|
||||
self.webserverStarted = False
|
||||
self.HTML_PSEUDO_TITLE = htmlPseudoTitle
|
||||
try:
|
||||
self.my_logger = logging.getLogger('MyLogger')
|
||||
self.my_logger.setLevel(logging.DEBUG)
|
||||
@@ -217,7 +219,7 @@ class PseudoDailyScheduleController():
|
||||
with tag('div', klass='row make-white'):
|
||||
with tag('div'):
|
||||
with tag('div'):
|
||||
line('h1', "Daily Pseudo Schedule", klass='col-12 pl-0')
|
||||
line('h1', self.HTML_PSEUDO_TITLE, klass='col-12 pl-0')
|
||||
with tag('div'):
|
||||
line('h3', time, klass='col-12 pl-1')
|
||||
with tag('table', klass='col-12 table table-bordered table-hover'):
|
||||
|
||||
Reference in New Issue
Block a user