From 0cf8fb2617952b5434341f57ea88b4b6bd550d69 Mon Sep 17 00:00:00 2001 From: John Marino Date: Fri, 6 Jun 2014 18:56:40 +0000 Subject: [PATCH] www/lionwiki: Stage support, reset maintainer There were modifications made to the PR patch that was submitted to stage this port: * Use @owner, @group pkg-list keywords instead of $CHOWN in stagedir * Use @sample keyword instead of old-style conf file handling * post-patch target unnecessary; file doesn't need to be MV'd twice * post-install target unnecessary with stage (pkg-message handled is automatically) * pet portlint with WWW whitespace fix * Reset MIA maintainer PR: ports/190225 Submitted by: Joe Benden Modified by: marino --- www/lionwiki/Makefile | 23 +++++++---------------- www/lionwiki/pkg-descr | 2 +- www/lionwiki/pkg-plist | 8 +++++--- 3 files changed, 13 insertions(+), 20 deletions(-) diff --git a/www/lionwiki/Makefile b/www/lionwiki/Makefile index b67d7b34eb69..1c2a4363a9d4 100644 --- a/www/lionwiki/Makefile +++ b/www/lionwiki/Makefile @@ -6,33 +6,24 @@ PORTVERSION= 3.2.7 CATEGORIES= www MASTER_SITES= http://lionwiki.0o.cz/download/${PORTVERSION}/ -MAINTAINER= sylvio@FreeBSD.org +MAINTAINER= ports@FreeBSD.org COMMENT= Minimalis wiki, extensible, templatable and file based USE_PHP= session ctype -#NO_WRKSUBDIR= yes NO_BUILD= yes ROOTFILES= config.php index.php ROOTDIRS= lang plugins templates var SUB_FILES= pkg-message - -NO_STAGE= yes -post-patch: - (cd ${WRKSRC} && ${MV} config.php config.php.sample) +PLIST_SUB= OWNER=${WWWOWN} GROUP=${WWWGRP} do-install: - ${MKDIR} ${WWWDIR} - ${INSTALL_DATA} ${WRKSRC}/config.php.sample ${WWWDIR}/ - if [ ! -f ${WWWDIR}/config.php ]; then \ - ${CP} -p ${WWWDIR}/config.php.sample ${WWWDIR}/config.php; \ - fi - ${INSTALL_DATA} ${WRKSRC}/index.php ${WWWDIR}/ + ${MKDIR} ${STAGEDIR}${WWWDIR} + ${INSTALL_DATA} ${WRKSRC}/config.php \ + ${STAGEDIR}${WWWDIR}/config.php.sample + ${INSTALL_DATA} ${WRKSRC}/index.php ${STAGEDIR}${WWWDIR}/ .for dirs in ${ROOTDIRS} - (cd ${WRKSRC} && ${COPYTREE_SHARE} ${dirs} ${WWWDIR}/ ) + cd ${WRKSRC} && ${COPYTREE_SHARE} ${dirs} ${STAGEDIR}${WWWDIR}/ .endfor - ${CHOWN} -R ${WWWOWN}:${WWWGRP} ${WWWDIR} -post-install: - ${CAT} ${PKGMESSAGE} .include diff --git a/www/lionwiki/pkg-descr b/www/lionwiki/pkg-descr index 3f25d282934a..3aaf1fbe18e3 100644 --- a/www/lionwiki/pkg-descr +++ b/www/lionwiki/pkg-descr @@ -3,4 +3,4 @@ templatable, file based (it doesn't need database like MySQL) and requires just one file to function. It's suitable for small websites, personal notebooks or journals. -WWW: http://lionwiki.0o.cz +WWW: http://lionwiki.0o.cz diff --git a/www/lionwiki/pkg-plist b/www/lionwiki/pkg-plist index f10a294141c5..fc5e01570b1a 100644 --- a/www/lionwiki/pkg-plist +++ b/www/lionwiki/pkg-plist @@ -1,6 +1,6 @@ -@unexec if cmp -s %D/%%WWWDIR%%/config.php %D/%%WWWDIR%%/config.php.sample; then rm -f %D/%%WWWDIR%%/config.php; else %%ECHO_MSG%% "===> Customized %D/%%WWWDIR%%/config.php has not been removed"; fi -%%WWWDIR%%/config.php.sample -@exec if [ ! -f %D/%%WWWDIR%%/config.php ] ; then cp -p %D/%F %B/config.php; fi +@owner %%OWNER%% +@group %%GROUP%% +@sample %%WWWDIR%%/config.php.sample %%WWWDIR%%/index.php %%WWWDIR%%/lang/ar.php %%WWWDIR%%/lang/cs.php @@ -68,6 +68,8 @@ %%WWWDIR%%/templates/red.html %%WWWDIR%%/templates/terminal.html %%WWWDIR%%/templates/wikiss.html +@owner +@group @dirrm %%WWWDIR%%/var @dirrm %%WWWDIR%%/templates @dirrm %%WWWDIR%%/plugins/Menu