Skip to content

Commit e37a92c

Browse files
authored
Visual cleanup
Moved hardset commandline options to top of file. ToDo: Change plextoken sed scripting to XML parser to extract the token value. Currently remove option won't remove the old tar.bz if its actively installing a new version, may want to change that logic to get it all taken care of in one action. Will remove it if run a second time though.
1 parent a6306e7 commit e37a92c

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

PMS_Updater.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
#!/bin/sh
22

3+
AUTOUPDATE=1
4+
FORCEUPDATE=0
5+
VERBOSE=1
6+
REMOVE=1
7+
LOGGING=1
8+
39
PLEXTOKEN="$(sed -n 's/.*PlexOnlineToken="//p' /Plex\ Media\ Server/Preferences.xml | sed 's/\".*//')"
410
BASEURL="https://plex.tv/api/downloads/5.json"
511
TOKENURL="$BASEURL?channel=plexpass&X-Plex-Token=$PLEXTOKEN"
@@ -9,12 +15,6 @@ LOGFILE="PMS_Updater.log"
915
PMSPARENTPATH="/usr/local/share"
1016
PMSPATTERN="PlexMediaServer-[0-9]*.[0-9]*.[0-9]*.[0-9]*-[0-9,a-f]*-FreeBSD-amd64.tar.bz2"
1117

12-
AUTOUPDATE=0
13-
FORCEUPDATE=0
14-
VERBOSE=0
15-
REMOVE=0
16-
LOGGING=1
17-
1818
# Initialize CURRENTVER to the script max so if reading the current version fails
1919
# for some reason we don't blindly clobber things
2020
CURRENTVER=9999.9999.9999.9999.9999

0 commit comments

Comments
 (0)