From owner-svn-ports-all@freebsd.org Sun Mar 27 19:11:08 2016 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 32DC2ADF3ED; Sun, 27 Mar 2016 19:11:08 +0000 (UTC) (envelope-from pi@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id F3EF317C0; Sun, 27 Mar 2016 19:11:07 +0000 (UTC) (envelope-from pi@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u2RJB76N042440; Sun, 27 Mar 2016 19:11:07 GMT (envelope-from pi@FreeBSD.org) Received: (from pi@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u2RJB6gA042432; Sun, 27 Mar 2016 19:11:06 GMT (envelope-from pi@FreeBSD.org) Message-Id: <201603271911.u2RJB6gA042432@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: pi set sender to pi@FreeBSD.org using -f From: Kurt Jaeger Date: Sun, 27 Mar 2016 19:11:06 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r412010 - in head/multimedia: . plexwatch plexwatch/files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 27 Mar 2016 19:11:08 -0000 Author: pi Date: Sun Mar 27 19:11:06 2016 New Revision: 412010 URL: https://svnweb.freebsd.org/changeset/ports/412010 Log: New port: multimedia/plexwatch Notify and log 'Now Playing', 'Watched' and 'Recently Added' content from a Plex Media Server (...and more) WWW: https://github.com/ljunkie/plexWatch PR: 208315 Submitted by: Ultima1252@gmail.com Added: head/multimedia/plexwatch/ head/multimedia/plexwatch/Makefile (contents, props changed) head/multimedia/plexwatch/distinfo (contents, props changed) head/multimedia/plexwatch/files/ head/multimedia/plexwatch/files/patch-plexWatch.pl (contents, props changed) head/multimedia/plexwatch/files/pkg-message.in (contents, props changed) head/multimedia/plexwatch/pkg-descr (contents, props changed) head/multimedia/plexwatch/pkg-plist (contents, props changed) Modified: head/multimedia/Makefile Modified: head/multimedia/Makefile ============================================================================== --- head/multimedia/Makefile Sun Mar 27 17:58:54 2016 (r412009) +++ head/multimedia/Makefile Sun Mar 27 19:11:06 2016 (r412010) @@ -302,6 +302,7 @@ SUBDIR += plexmediaserver SUBDIR += plexmediaserver-plexpass SUBDIR += plexpy + SUBDIR += plexwatch SUBDIR += podcastdl SUBDIR += poe SUBDIR += ppm2fli Added: head/multimedia/plexwatch/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/plexwatch/Makefile Sun Mar 27 19:11:06 2016 (r412010) @@ -0,0 +1,56 @@ +# Created by: ultima +# $FreeBSD$ + +PORTNAME= plexWatch +PORTVERSION= 0.3.3 +DISTVERSIONPREFIX= v +CATEGORIES= multimedia + +MAINTAINER= ultima1252@gmail.com +COMMENT= Notify, Log Now Playing and Watched content from a Plex Media Server + +RUN_DEPENDS= p5-libwww>=0:${PORTSDIR}/www/p5-libwww \ + p5-XML-Simple>=0:${PORTSDIR}/textproc/p5-XML-Simple \ + p5-DBI>=0:${PORTSDIR}/databases/p5-DBI \ + p5-Time-Duration>=0:${PORTSDIR}/devel/p5-Time-Duration \ + p5-Time-modules>=0:${PORTSDIR}/devel/p5-Time-modules \ + p5-JSON>=0:${PORTSDIR}/converters/p5-JSON \ + p5-DBD-SQLite>=0:${PORTSDIR}/databases/p5-DBD-SQLite \ + p5-LWP-Protocol-https>=0:${PORTSDIR}/www/p5-LWP-Protocol-https + +USES= perl5 shebangfix +SHEBANG_FILES= plexWatch.pl + +USE_GITHUB= yes +GH_ACCOUNT= ljunkie +NO_BUILD= yes + +SUB_FILES= pkg-message + +OPTIONS_DEFINE= EMAIL GNTP IPLOG TWITTER +OPTIONS_DEFAULT= + +EMAIL_RUN_DEPENDS= p5-Net-SMTPS>=0:${PORTSDIR}/mail/p5-Net-SMTPS +EMAIL_DESC= Email support + +GNTP_RUN_DEPENDS= p5-Growl-GNTP>=0:${PORTSDIR}/net/p5-Growl-GNTP +GNTP_DESC= Growl GNTP support + +IPLOG_RUN_DEPENDS= p5-File-ReadBackwards>=0:${PORTSDIR}/devel/p5-File-ReadBackwards +IPLOG_DESC= Client IP logging support + +TWITTER_RUN_DEPENDS= p5-Net-Twitter-Lite>=0:${PORTSDIR}/net/p5-Net-Twitter-Lite \ + p5-Net-OAuth>=0:${PORTSDIR}/net/p5-Net-OAuth +TWITTER_DESC= Twitter support + +post-patch: + ${REINPLACE_CMD} "s|%%ETCDIR%%|${ETCDIR}|" ${WRKSRC}/plexWatch.pl + ${REINPLACE_CMD} "s|/opt/plexWatch|${DATADIR}|" ${WRKSRC}/config.pl-dist + +do-install: + ${MKDIR} ${STAGEDIR}${ETCDIR} + ${MKDIR} -m 777 ${STAGEDIR}${DATADIR} + ${INSTALL_SCRIPT} ${WRKSRC}/plexWatch.pl ${STAGEDIR}${PREFIX}/sbin/ + ${INSTALL_DATA} ${WRKSRC}/config.pl-dist ${STAGEDIR}${ETCDIR}/ + +.include Added: head/multimedia/plexwatch/distinfo ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/plexwatch/distinfo Sun Mar 27 19:11:06 2016 (r412010) @@ -0,0 +1,2 @@ +SHA256 (ljunkie-plexWatch-v0.3.3_GH0.tar.gz) = 15cb0eb9f7376ae2f409e9dbb6fa5c5bb5d3549c69fe1e36e48ac016a81c38d4 +SIZE (ljunkie-plexWatch-v0.3.3_GH0.tar.gz) = 6521319 Added: head/multimedia/plexwatch/files/patch-plexWatch.pl ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/plexwatch/files/patch-plexWatch.pl Sun Mar 27 19:11:06 2016 (r412010) @@ -0,0 +1,21 @@ +--- plexWatch.pl.orig 2016-03-26 19:12:31 UTC ++++ plexWatch.pl +@@ -42,15 +42,14 @@ if ($^O ne 'MSWin32') { + ## end + + ## load config file +-my $dirname = dirname(__FILE__); +-if (!-e $dirname .'/config.pl') { +- my $msg = "** missing file $dirname/config.pl. Did you move edit config.pl-dist and copy to config.pl?"; ++if (!-e '%%ETCDIR%%/config.pl') { ++ my $msg = "** missing file %%ETCDIR%%/config.pl. Did you move edit config.pl-dist and copy to config.pl?"; + &DebugLog($msg,1) if $msg; + exit; + } + 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); + 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"); +-do $dirname.'/config.pl'; ++do '%%ETCDIR%%/config.pl'; + + if (!$data_dir || !$server || !$port || !$appname || !$alert_format || !$notify) { + ## TODO - make this information a little more useful! Added: head/multimedia/plexwatch/files/pkg-message.in ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/plexwatch/files/pkg-message.in Sun Mar 27 19:11:06 2016 (r412010) @@ -0,0 +1,8 @@ +plexWatch needs to run frequently, this is a suggested cron job + +* * * * * nobody %%PREFIX%%/sbin/plexWatch.pl + + +Optionally, if you want recently added notifications, add this + +*/15 * * * * nobody %%PREFIX%%/sbin/plexWatch.pl --recently_added=movie,tv Added: head/multimedia/plexwatch/pkg-descr ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/plexwatch/pkg-descr Sun Mar 27 19:11:06 2016 (r412010) @@ -0,0 +1,4 @@ +Notify and log 'Now Playing', 'Watched' and 'Recently Added' content +from a Plex Media Server (...and more) + +WWW: https://github.com/ljunkie/plexWatch Added: head/multimedia/plexwatch/pkg-plist ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/multimedia/plexwatch/pkg-plist Sun Mar 27 19:11:06 2016 (r412010) @@ -0,0 +1,3 @@ +%%ETCDIR%%/config.pl-dist +sbin/plexWatch.pl +@dir %%DATADIR%%