plexWatch - Windows Branch

plexWatch v0.3.3 Released (2015-03-29)

 

Requirements:
* PMS 0.9.11.4 or greater
* PlexPass subscription ( everything but recently added content )
* PMS logs ( with debug enabled ) if you want IP logging
* Clients that support Now Playing  i.e. user must show up in now playing on plex/Web
                                                       note: PMC does not work - use PHT
* Recently added notifications will work with any current version.

 

DownloadsplexWatch.exe and config.pl-dist-win32   ( I will be adding a windows directory for binaries for the final release )

 * VBS scripts:  plexWatchNotify.vbs & plexWatchRecentlyAdded.vbs

 

GitHub:https://github.com/ljunkie/plexWatch (source: plexWatch.pl )

 

Screenshots: iOS Boxcar // iOS Prowl // iOS Pushover // Win7 Growl

 

Please use the plexWatch.exe and config.pl-dist-win32 instead of the plexWatch.pl/config.pl-dist files (even though it's included in the repo/zip)

 

I also suggest to edit the config.pl in notepad++

 

 

** Install Notes **

 

Install

* unzip contents to c:\plexWatch\

* rename config.pl-dist-win32 to c:\plexWatch\config.pl

* Edit (with notepad++) c:\plexWatch\config.pl

* open a command prompt 

* cd c:\plexWatch

* run: plexWatch.exe   (and verify no errors -- don't expect any output yet)

 

Test the script:

* open a command prompt 

* cd c:\plexWatch

* start a show

* run: plexWatch.exe

* stop the show

* run: plexWatch.exe

 

Automatically notify/log watching/watched content:  ( You must enable this script for plexWatch to work )

* schedule a task (every minute) to execute c:\plexWatch\plexWatchNotify.vbs  ( specify the start in folder as c:\plexWatch\

 

Automatically notify on Recently Added Content:

* schedule a task (every 5 minutes or more) to execute c:\plexWatch\plexWatchRecentlyAdded.vbs  ( specify the start in folder as c:\plexWatch\

 

 

* IP logging: log location: http://forums.plexapp.com/index.php/topic/25417-where-are-the-pms-logs-on-windows/

 

 

Frontends

 


Things known not to work

* --start= , --stop= options on the cli:  not a huge deal and can possible be fixed later

reserved

TODO: verify install/running how to instructions. I would appreciate anyone who runs this on windows to write something up. I don't use windows for my server, so I'd prefer someone who actually uses this daily to write something. I have included a brief Install/Howto above, but it's lame. Thanks!

TODO: verify install/running how to instructions. I would appreciate anyone who runs this on windows to write something up. I don't use windows for my server, so I'd prefer someone who actually uses this daily to write something. I have included a brief Install/Howto above, but it's lame. Thanks!

If you need anything special to be tested I might be up for it!

So far I've got the basic fonction to be working. (Ie --watched, --watching) I haven't checked much since its pretty much what i was looking for in the first place.

If you need anything special to be tested I might be up for it!

So far I've got the basic fonction to be working. (Ie --watched, --watching) I haven't checked much since its pretty much what i was looking for in the first place.

Anything you find that isn't working would be great as I don't really use windows for much. 

TODO: verify install/running how to instructions. I would appreciate anyone who runs this on windows to write something up. I don't use windows for my server, so I'd prefer someone who actually uses this daily to write something. I have included a brief Install/Howto above, but it's lame. Thanks!

I just got this setup moments ago, was looking for instructions but did it on my own in the end. I did exactly what you have listed and it works great. I can confirm Pushover works as well. 

If all seems to work after this: 

* schedule a task (every minute) to execute c:\plexWatch\plexWatch.exe

 

 

Have at it and let me know of any issues!

Ensure when you schedule the task you specify the start in folder as c:\plexWatch\  It would not work for me until I did that. Said it could not find config.pl

Pushover does work (as said above)

Seems like there's a bug, not with Pushover itseft. (Pic)

-> plexwatch.exe --test_notify=[arg]

-> plexwatch.pl --test_notify=[arg]

:: [T] [2013] - i'm assuming [t] stand for the current time(H:M:S) 

:: Command prompt is also telling me that it's sending the [T] nothing to do with Pushover.

:: OS French-Win7-Pro installed

edit: p.s: I've Strawberry perl installed and did get all module, except "Time::ParseDate" which seems to fail when doing cpan install Time::ParseDate

Edit 2 :

My bad, just kind of exicted that this was actually working now. I'll get to read these now.

Pushover does work (as said above)

Seems like there's a bug, not with Pushover itseft. (Pic)
-> plexwatch.exe --test_notify=[arg]
->plexwatch.pl --test_notify=[arg]
:: [T] [2013] - i'm assuming [t] stand for the current time(H:M:S)
:: Command prompt is also telling me that it's sending the [T] nothing to do with Pushover.
:: OS French-Win7-Pro installed

Remember, there is no need to use the .pl file.. The .exe is bundled and is the one I will support/troubleshoot.

[T] is telling you the video was transcoded instead of [D] direct play

Please have a look at https://github.com/ljunkie/plexWatch/blob/master/README.md#using-the-script which explains a lot about the program.

* notification format info: https://github.com/ljunkie/plexWatch/blob/master/README.md#notification-format
* It can all me modified in the config.pl to suit your needs

Any questions are welcomed as these may answer questions others have :)

edit: p.s: I've Strawberry perl installed and did get all module, except "Time::ParseDate" which seems to fail when doing cpan install Time::ParseDate


Strawberry perl will work fine. I suggest though to only use the .exe and not even worry about installing perl since its all bundled in the exe I released.

Time::ParseDate has been excluded for now in the windows version due to build problems. At some point I might include this if it ever works or move to something else.

The issue I am having is configuration on the config.pl file. I notice you have a user name (frank) is that along with the roku 3… Ect. Supposed to be changed to what I want? I have about 11 different devices like PHT and android GTV. How do I go about adding those? And finally how do I know what needs to be configured. I have technical background but, when it comes to coding I have no clue whats going on. So my input would be to have more detail on specifics and what to configure. Thanks again for all your hard work.


Chris

The issue I am having is configuration on the config.pl file. I notice you have a user name (frank) is that along with the roku 3.... Ect. Supposed to be changed to what I want? I have about 11 different devices like PHT and android GTV. How do I go about adding those? And finally how do I know what needs to be configured. I have technical background but, when it comes to coding I have no clue whats going on. So my input would be to have more detail on specifics and what to configure. Thanks again for all your hard work.

Chris

Chris - Yea, sadly this forums doesn't have all the good info the main one does. Feel free for one to post questions there and use this forum post for any BUGS you find. The only reason I say that is the fact more users look at the original forum topic. I will try and answer some of your questions here though. 

The $users_display is ONLY for aesthetics and can definitely be modified after the fact, so you don't have to worry if you have that right before you start using plexWatch every minute. The best thing to do is setup all the myplex usernames with a friendly name first, before you start thinking about all the devices. It's much easier to modify the config.pl file with the username+device after you have the devices logged so you can tell what the device name is. 

Do you have any output from "plexWatch.exe --watched" yet?  If so, please post that here and I can explain how to setup the $users_display 

As it is, nothing in the config.pl really needs to be modified until you know what you want :) Do you want push notifications? If so, do you want them to growl, pushover, prowl, etc? Go ahead and let me know what you are looking to do and I can explain it further if needed. I also am not sure if growl works yet for notification in windows. The others should excluding growl and or twitter.

Got this up and running with pushover last night.

Only issue I had initially was getting pushover installed with curl, I overlooked one of the install steps.

But after that all seems to be working fine.

IP logging is working as well as the "friendly name" feature.

Got this up and running with pushover last night.
Only issue I had initially was getting pushover installed with curl, I overlooked one of the install steps.

But after that all seems to be working fine.
IP logging is working as well as the "friendly name" feature.


What issues do you have with curl? I'm confused because the .exe should take all the hard work out the installation.

From the pushover.net site instructions for windows:

How do I send Pushover notifications from a Windows command line?
The curl program may be used, replacing "APP_TOKEN" with the token of your app, and "USER_KEY" with your user's key (or your own if sending messages to your own devices). Download a Win32 build with SSL support and run the "mk-ca-bundle" script to generate the CA bundle.

it was the "and run the "mk-ca-bundle" script to generate the CA bundle" that I didn't catch at first.
After I ran that vbs script everything worked fine.

From the pushover.net site instructions for windows:

it was the "and run the "mk-ca-bundle" script to generate the CA bundle" that I didn't catch at first.
After I ran that vbs script everything worked fine.

Thanks. I had no idea this was required as plexWatch.exe is it's owned contained version. I will verify this issue and add it to the install instructions!

as plexWatch.exe has it's owned contained version.

I didn't realize that, so I didn't even try to just add the pushover keys to the config.pl file to see if it worked.

I installed pushover.net per their website instructions before editing the config.pl file

When I run plexwatch.exe -- stats I get the following error after each user, any ideas?

user: Local's total duration 4 minutes
Argument "2013-9-2" isn't numeric in localtime at plexWatch.pl line 618, 
line 176.
 %a %b %e %Y: Local 4 minutes

The line of code its complaining about is this:

my $h_date = strftime "%a %b %e %Y", localtime($epoch);

When I run plexwatch.exe -- stats I get the following error after each user, any ideas?

user: Local's total duration 4 minutes
Argument "2013-9-2" isn't numeric in localtime at plexWatch.pl line 618, 
line 176.
 %a %b %e %Y: Local 4 minutes

Finally a bug :) yea I had to make some changes because windows/perl doesn't have Time::ParseDate -- so this much be the side effect. I will see if I can get this fix in a little bit. Don't worry though,all the data is logged -- just not parsing correctly on output. 

Awesome! Thanks.