summaryrefslogtreecommitdiff
path: root/www/SNIP
diff options
context:
space:
mode:
Diffstat (limited to 'www/SNIP')
-rw-r--r--www/SNIP/Makefile59
-rw-r--r--www/SNIP/distinfo3
-rw-r--r--www/SNIP/files/pkg-message.in20
-rw-r--r--www/SNIP/pkg-descr24
4 files changed, 106 insertions, 0 deletions
diff --git a/www/SNIP/Makefile b/www/SNIP/Makefile
new file mode 100644
index 000000000000..9f7b1550b139
--- /dev/null
+++ b/www/SNIP/Makefile
@@ -0,0 +1,59 @@
+PORTNAME= SNIP
+DISTVERSIONPREFIX= v
+DISTVERSION= 1.1.0
+CATEGORIES= www
+
+MAINTAINER= ek@purplehat.org
+COMMENT= SNIP is a powerful, simple, and easy to use Open-Source PHP Pastebin
+WWW= https://github.com/MercanoGlobal/SNIP
+
+LICENSE= GPLv3
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+USES= php:web
+
+USE_GITHUB= yes
+GH_ACCOUNT= MercanoGlobal
+
+USE_PHP= ctype filter gd session
+
+NO_ARCH= yes
+NO_BUILD= yes
+
+SUB_FILES= pkg-message
+PLIST_SUB+= WWWGRP="${WWWGRP}" \
+ WWWOWN="${WWWOWN}"
+
+OPTIONS_DEFAULT= MYSQLI
+OPTIONS_SINGLE= DB
+OPTIONS_SINGLE_DB= MYSQLI PGSQL SQLITE
+
+MYSQLI_DESC= Install MySQLi Support for PHP
+
+MYSQLI_USE= PHP=mysqli
+PGSQL_USES= pgsql
+PGSQL_USE= PHP=pgsql
+SQLITE_USES= sqlite
+SQLITE_USE= PHP=sqlite3
+
+do-install:
+ ${MKDIR} ${STAGEDIR}${ETCDIR}
+ ${MKDIR} ${STAGEDIR}${WWWDIR}
+ (cd ${WRKSRC}/htdocs && ${COPYTREE_SHARE} . ${STAGEDIR}${WWWDIR})
+ ${FIND} ${STAGEDIR}${WWWDIR} -type f -iname "*.orig" -delete
+ ${INSTALL_DATA} ${STAGEDIR}${WWWDIR}/application/config/snip.php.dist ${STAGEDIR}${ETCDIR}/snip.php.sample
+ ${LN} -sf ${ETCDIR}/snip.php ${STAGEDIR}${WWWDIR}/application/config/
+
+post-install:
+ @${ECHO_CMD} "@owner ${WWWOWN}" >> ${TMPPLIST}
+ @${ECHO_CMD} "@group ${WWWGRP}" >> ${TMPPLIST}
+ ${FIND} -s ${STAGEDIR}${ETCDIR} -not -type d | ${SORT} | \
+ ${SED} -e 's#^${STAGEDIR}${ETCDIR}#${ETCDIR_REL}#' | \
+ ${SED} -E -e '/sample$$/ s#^#@sample(,,0640) #;' >> ${TMPPLIST}
+ ${FIND} -s ${STAGEDIR}${WWWDIR} -not -type d | ${SORT} | \
+ ${SED} -e 's#^${STAGEDIR}${PREFIX}/##' | \
+ ${SED} -E -e '/snip.php(\.dist)?/ s#^#@(,,0640) #;' >> ${TMPPLIST}
+ ${FIND} -s ${STAGEDIR}${WWWDIR} -type d -exec echo "@dir {}" \; | ${SORT} | \
+ ${SED} -e 's#^@dir ${STAGEDIR}${PREFIX}/#@dir #' >> ${TMPPLIST}
+
+.include <bsd.port.mk>
diff --git a/www/SNIP/distinfo b/www/SNIP/distinfo
new file mode 100644
index 000000000000..6d5aebe1c581
--- /dev/null
+++ b/www/SNIP/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1745194264
+SHA256 (MercanoGlobal-SNIP-v1.1.0_GH0.tar.gz) = 94c6461b7b7f4b823148bac47e9d7fa0510d593aa8fce5c6a70ccc0ddd2a6893
+SIZE (MercanoGlobal-SNIP-v1.1.0_GH0.tar.gz) = 15305696
diff --git a/www/SNIP/files/pkg-message.in b/www/SNIP/files/pkg-message.in
new file mode 100644
index 000000000000..cd4a6724162c
--- /dev/null
+++ b/www/SNIP/files/pkg-message.in
@@ -0,0 +1,20 @@
+[
+{ type: install
+ message: <<EOM
+The configuration file is in %%ETCDIR%%/snip.php
+
+This package contains a true_paste feature which has been sent
+upstream but has not yet been included.
+
+There are the minimal configuration items:
+
+Set driver to one of:
+
+* 'postgres'
+* 'mysqli'
+* 'sqlite'
+
+Set appropriate values in the 'Database connection' section.
+EOM
+}
+]
diff --git a/www/SNIP/pkg-descr b/www/SNIP/pkg-descr
new file mode 100644
index 000000000000..9dfe9a5699bb
--- /dev/null
+++ b/www/SNIP/pkg-descr
@@ -0,0 +1,24 @@
+SNIP is a powerful Open-Source PHP Pastebin, with the aim of keeping
+a simple and easy to use user interface. SNIP allows you to easily
+share code and files with anyone you wish. Based on the original
+Stikked with lots of bug fixes and improvements.
+
+Prerequisites:
+* A web server: Apache, LiteSpeed, Nginx, Lighttpd, Cherokee.
+* A database: MySQL / MariaDB, Postgres. OR a writable folder for SQLite.
+* PHP version 7.0 or newer is required.
+* PHP-GD for the creation of QR-codes.
+
+Here are some features:
+* Syntax highlighting including live highlighting with CodeMirror
+* Paste replies
+* Diff view between the original paste and the reply
+* An API
+* Trending pastes
+* Encrypted pastes
+* Burn on reading
+* File upload and preview
+* Anti-Spam features
+* Multilanguage support
+* SNIP client with support for client side encryption/decryption: gostikkit
+* Another CLI tool requiring only curl program: pbin