summaryrefslogtreecommitdiff
path: root/app-text/dictd/files/1.10.11
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /app-text/dictd/files/1.10.11
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'app-text/dictd/files/1.10.11')
-rw-r--r--app-text/dictd/files/1.10.11/colorit.conf32
-rw-r--r--app-text/dictd/files/1.10.11/dict.conf6
-rw-r--r--app-text/dictd/files/1.10.11/dictd.conf26
-rw-r--r--app-text/dictd/files/1.10.11/dictd.confd5
-rw-r--r--app-text/dictd/files/1.10.11/dictd.initd77
-rw-r--r--app-text/dictd/files/1.10.11/site.info6
6 files changed, 152 insertions, 0 deletions
diff --git a/app-text/dictd/files/1.10.11/colorit.conf b/app-text/dictd/files/1.10.11/colorit.conf
new file mode 100644
index 000000000000..22b00e9ec07d
--- /dev/null
+++ b/app-text/dictd/files/1.10.11/colorit.conf
@@ -0,0 +1,32 @@
+dnl /etc/dictd/colorit.conf vim:ft=m4
+dnl
+dnl Sample configuration file for colorit(1) program
+dnl
+divert(-1)
+dnl
+dnl Define some useful color variables
+dnl
+define(`black', `0')
+define(`red', `1')
+define(`green', `2')
+define(`brown', `3')
+define(`blue', `4')
+define(`magenta', `5')
+define(`cyan', `6')
+define(`white', `7')
+dnl
+dnl Mark macro arguments: regexp foreground-color [background-color]
+dnl
+define(`mark', ``mark "$1"'' `ifelse(`$#', `3', ``"\033[3$2;4$3m"'', ``"\033[3$2m"'')' `"\033[m"')
+dnl
+divert
+mark(`^From.*$',red,cyan)
+mark(`^ [^ ]+',green)
+mark(`^ *Note:',red)
+mark(`{[^{]+}',green)
+mark(`^ *\[[^\[]+\]', cyan)
+mark(`^[ ]*(adj|n|v|adv)? *[0-9]+[\.:]',cyan)
+mark(`^ *\([a-z]+\)',cyan)
+mark(`(Syn|Ant|syn|ant):', blue, white)
+mark(` (t|i|a|adj|adv|n|v)\. ',cyan)
+mark(` (t|i|a|adj|adv|n|v)\.$',cyan)
diff --git a/app-text/dictd/files/1.10.11/dict.conf b/app-text/dictd/files/1.10.11/dict.conf
new file mode 100644
index 000000000000..e06c3d296ec3
--- /dev/null
+++ b/app-text/dictd/files/1.10.11/dict.conf
@@ -0,0 +1,6 @@
+# This is the configuration file for dict.
+# Usually all you will ever need here is the server keywords.
+# Refer to the dict manpage for other options.
+# It will only check the second server if the first fails
+server localhost
+server dict.org
diff --git a/app-text/dictd/files/1.10.11/dictd.conf b/app-text/dictd/files/1.10.11/dictd.conf
new file mode 100644
index 000000000000..0de4c201773a
--- /dev/null
+++ b/app-text/dictd/files/1.10.11/dictd.conf
@@ -0,0 +1,26 @@
+# dictd configuration file
+
+global {
+ # Informational message
+ site site.info
+}
+
+# who's allowed. You might want to change this.
+access {
+ allow *
+}
+
+# Dictionaries are listed below. During dictd startup the OpenRC init script will
+# scan ${DLIBDIR} (see /etc/conf.d/dictd) and adds all of the dictionaries it
+# finds here.
+#
+# On the other hand, if you are running systemd, you will need to look at
+# /usr/share/doc/dictd-${PV}/dictd.conf.example as reference to know the format
+# of the lines you will need to manually add below.
+#
+# NOTE: OpenRC init script will wipe everything below #LASTLINE and replace it with
+# what it finds. So add all of your things above. If this is a problem, report
+# bug at https://bugs.gentoo.org, please.
+#
+# Do not remove next line!
+#LASTLINE
diff --git a/app-text/dictd/files/1.10.11/dictd.confd b/app-text/dictd/files/1.10.11/dictd.confd
new file mode 100644
index 000000000000..06eb94973bfa
--- /dev/null
+++ b/app-text/dictd/files/1.10.11/dictd.confd
@@ -0,0 +1,5 @@
+# If you have problems starting dictd in a UTF-8 locale, add an appropriate
+# --locale switch to DICTD_OPTS, e. g. "--locale=en_US.utf8"
+DICTD_OPTS="-s "
+DICTDCONF=/etc/dict/dictd.conf
+DLIBDIR=/usr/lib/dict
diff --git a/app-text/dictd/files/1.10.11/dictd.initd b/app-text/dictd/files/1.10.11/dictd.initd
new file mode 100644
index 000000000000..ca4474043bcf
--- /dev/null
+++ b/app-text/dictd/files/1.10.11/dictd.initd
@@ -0,0 +1,77 @@
+#!/sbin/openrc-run
+# Copyright 1999-2016 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+DICTD_PID="/var/run/dictd.pid"
+
+prepconfig() {
+ local TMPCONF INDEXFILES CNT DNAME DICT SAVEDIR
+ if [ ! -e "${DICTDCONF}" ]; then
+ eerror "Config file ${DICTDCONF} not found."
+ return 1
+ fi
+
+ # if no dictionaries, skip startup.
+ # The new way of doing this is to scan /usr/lib/dict and tweek the conf
+ einfo "Scanning for dictionaries..."
+ if [ ! -d "${DLIBDIR}" ]; then
+ eerror "${DLIBDIR} doesn't exist, no dictionaries found."
+ return 1
+ fi
+
+ SAVEDIR=${PWD}
+ cd "${DLIBDIR}"
+ INDEXFILES=$(ls *.index)
+ if [ -z "${INDEXFILES}" ]; then
+ eerror "No dictionaries found at ${DLIBDIR}."
+ eerror "Please, emerge at least one of app-dicts/dictd-* dictionaries."
+ return 1
+ fi
+
+ TMPCONF=$(mktemp -t dictd.conf.XXXXXXXXXX)
+ cat ${DICTDCONF} | sed -e '/^#LASTLINE/,$d' > ${TMPCONF}
+ echo "#LASTLINE" >> ${TMPCONF}
+
+ CNT=0
+ for i in ${INDEXFILES}; do
+ DNAME=$(echo $i | sed -e 's/[.]index$//')
+ #two possible names for a matching dictionary, check which is there.
+ if [ -f ${DNAME}.dict.dz ]; then
+ DICT=${DNAME}.dict.dz
+ elif [ -f ${DNAME}.dict ];then
+ DICT=${DNAME}.dict
+ else
+ ewarn "Index $i has no matching dictionaray..."
+ fi
+
+ #ok, go an index, and a dixtionary, append.
+ echo "database ${DNAME} { data \"${DLIBDIR}/${DICT}\"" >> ${TMPCONF}
+ echo " index \"${DLIBDIR}/$i\" }" >> ${TMPCONF}
+
+ CNT=$(expr ${CNT} + 1)
+ done
+
+ cd "${SAVEDIR}"
+ mv "${TMPCONF}" "${DICTDCONF}"
+ chown 0:dictd "${DICTDCONF}"
+ chmod g+r "${DICTDCONF}"
+ einfo "Done, ${CNT} dictionaries found."
+}
+
+depend() {
+ need localmount
+}
+
+start() {
+ prepconfig || return 1
+ ebegin "Starting dictd"
+ start-stop-daemon --start --quiet --pidfile ${DICTD_PID} --exec \
+ /usr/sbin/dictd -- --pid-file ${DICTD_PID} ${DICTD_OPTS}
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping dictd"
+ start-stop-daemon --stop --quiet --pidfile ${DICTD_PID} --exec /usr/sbin/dictd
+ eend $?
+}
diff --git a/app-text/dictd/files/1.10.11/site.info b/app-text/dictd/files/1.10.11/site.info
new file mode 100644
index 000000000000..23bfdeb61102
--- /dev/null
+++ b/app-text/dictd/files/1.10.11/site.info
@@ -0,0 +1,6 @@
+Welcome to your dictionary server dictd!
+
+This is an example site information file. It should contain information
+about any restricted databases and how users can obtain access. If may
+also contain other random data as you see fit.
+