View | Details | Raw Unified | Return to bug 208315 | Differences between
and this patch

Collapse All | Expand All

(-)multimedia/Makefile (+1 lines)
Lines 302-307 Link Here
302
    SUBDIR += plexmediaserver
302
    SUBDIR += plexmediaserver
303
    SUBDIR += plexmediaserver-plexpass
303
    SUBDIR += plexmediaserver-plexpass
304
    SUBDIR += plexpy
304
    SUBDIR += plexpy
305
    SUBDIR += plexwatch
305
    SUBDIR += podcastdl
306
    SUBDIR += podcastdl
306
    SUBDIR += poe
307
    SUBDIR += poe
307
    SUBDIR += ppm2fli
308
    SUBDIR += ppm2fli
(-)multimedia/plexwatch/Makefile (+56 lines)
Line 0 Link Here
1
# Created by: ultima <ultima1252@gmail.com>
2
# $FreeBSD$
3
4
PORTNAME=	plexWatch
5
PORTVERSION=	0.3.3
6
DISTVERSIONPREFIX=	v
7
CATEGORIES=	multimedia
8
9
MAINTAINER=	ultima1252@gmail.com
10
COMMENT=	Notify, Log Now Playing and Watched content from a Plex Media Server
11
12
RUN_DEPENDS=	p5-libwww>=0:${PORTSDIR}/www/p5-libwww \
13
		p5-XML-Simple>=0:${PORTSDIR}/textproc/p5-XML-Simple \
14
		p5-DBI>=0:${PORTSDIR}/databases/p5-DBI \
15
		p5-Time-Duration>=0:${PORTSDIR}/devel/p5-Time-Duration \
16
		p5-Time-modules>=0:${PORTSDIR}/devel/p5-Time-modules \
17
		p5-JSON>=0:${PORTSDIR}/converters/p5-JSON \
18
		p5-DBD-SQLite>=0:${PORTSDIR}/databases/p5-DBD-SQLite \
19
		p5-LWP-Protocol-https>=0:${PORTSDIR}/www/p5-LWP-Protocol-https
20
21
USES=		perl5 shebangfix
22
SHEBANG_FILES=	plexWatch.pl
23
24
USE_GITHUB=	yes
25
GH_ACCOUNT=	ljunkie
26
NO_BUILD=	yes
27
28
SUB_FILES=	pkg-message
29
30
OPTIONS_DEFINE=	EMAIL GNTP IPLOG TWITTER
31
OPTIONS_DEFAULT=
32
33
EMAIL_RUN_DEPENDS=	p5-Net-SMTPS>=0:${PORTSDIR}/mail/p5-Net-SMTPS
34
EMAIL_DESC=		Email support
35
36
GNTP_RUN_DEPENDS=	p5-Growl-GNTP>=0:${PORTSDIR}/net/p5-Growl-GNTP
37
GNTP_DESC=		Growl GNTP support
38
39
IPLOG_RUN_DEPENDS=	p5-File-ReadBackwards>=0:${PORTSDIR}/devel/p5-File-ReadBackwards
40
IPLOG_DESC=		Client IP logging support
41
42
TWITTER_RUN_DEPENDS=	p5-Net-Twitter-Lite>=0:${PORTSDIR}/net/p5-Net-Twitter-Lite \
43
			p5-Net-OAuth>=0:${PORTSDIR}/net/p5-Net-OAuth
44
TWITTER_DESC=		Twitter support
45
46
post-patch:
47
	${REINPLACE_CMD} "s|%%ETCDIR%%|${ETCDIR}|" ${WRKSRC}/plexWatch.pl
48
	${REINPLACE_CMD} "s|/opt/plexWatch|${DATADIR}|" ${WRKSRC}/config.pl-dist
49
50
do-install:
51
	${MKDIR} ${STAGEDIR}${ETCDIR}
52
	${MKDIR} -m 777 ${STAGEDIR}${DATADIR}
53
	${INSTALL_SCRIPT} ${WRKSRC}/plexWatch.pl ${STAGEDIR}${PREFIX}/sbin/
54
	${INSTALL_DATA} ${WRKSRC}/config.pl-dist ${STAGEDIR}${ETCDIR}/
55
56
.include <bsd.port.mk>
(-)multimedia/plexwatch/distinfo (+2 lines)
Line 0 Link Here
1
SHA256 (ljunkie-plexWatch-v0.3.3_GH0.tar.gz) = 15cb0eb9f7376ae2f409e9dbb6fa5c5bb5d3549c69fe1e36e48ac016a81c38d4
2
SIZE (ljunkie-plexWatch-v0.3.3_GH0.tar.gz) = 6521319
(-)multimedia/plexwatch/files/patch-plexWatch.pl (+21 lines)
Line 0 Link Here
1
--- plexWatch.pl.orig	2016-03-26 19:12:31 UTC
2
+++ plexWatch.pl
3
@@ -42,15 +42,14 @@ if ($^O ne 'MSWin32') {
4
 ## end
5
 
6
 ## load config file
7
-my $dirname = dirname(__FILE__);
8
-if (!-e $dirname .'/config.pl') {
9
-    my $msg = "** missing file $dirname/config.pl. Did you move edit config.pl-dist and copy to config.pl?";
10
+if (!-e '%%ETCDIR%%/config.pl') {
11
+    my $msg = "** missing file %%ETCDIR%%/config.pl. Did you move edit config.pl-dist and copy to config.pl?";
12
     &DebugLog($msg,1) if $msg;
13
     exit;
14
 }
15
 our ($data_dir, $server, $port, $appname, $user_display, $alert_format, $notify, $push_titles, $backup_opts, $myPlex_user, $myPlex_pass, $server_log, $log_client_ip, $debug_logging, $watched_show_completed, $watched_grouping_maxhr, $count_paused, $inc_non_library_content, @exclude_library_ids);
16
 my @config_vars = ("data_dir", "server", "port", "appname", "user_display", "alert_format", "notify", "push_titles", "backup_opts", "myPlex_user", "myPlex_pass", "server_log", "log_client_ip", "debug_logging", "watched_show_completed", "watched_grouping_maxhr", "count_paused", "exclude_library_ids");
17
-do $dirname.'/config.pl';
18
+do '%%ETCDIR%%/config.pl';
19
 
20
 if (!$data_dir || !$server || !$port || !$appname || !$alert_format || !$notify) {
21
     ## TODO - make this information a little more useful!
(-)multimedia/plexwatch/files/pkg-message.in (+8 lines)
Line 0 Link Here
1
plexWatch needs to run frequently, this is a suggested cron job
2
3
* * * * * nobody %%PREFIX%%/sbin/plexWatch.pl
4
5
6
Optionally, if you want recently added notifications, add this
7
8
*/15 * * * * nobody %%PREFIX%%/sbin/plexWatch.pl --recently_added=movie,tv
(-)multimedia/plexwatch/pkg-descr (+4 lines)
Line 0 Link Here
1
Notify and Log 'Now Playing' and 'Watched' content from a Plex Media Server
2
+ 'Recently Added' (...and more)
3
4
WWW: https://github.com/ljunkie/plexWatch
(-)multimedia/plexwatch/pkg-plist (+3 lines)
Line 0 Link Here
1
%%ETCDIR%%/config.pl-dist
2
sbin/plexWatch.pl
3
@dir %%DATADIR%%

Return to bug 208315