1 # --- T2-COPYRIGHT-NOTE-BEGIN ---
2 # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
4 # T2 SDE: misc/output/parse-config
5 # Copyright (C) 2004 - 2007 The T2 SDE Project
6 # Copyright (C) 1998 - 2003 ROCK Linux Project
8 # More information can be found in the files COPYING and README.
10 # This program is free software; you can redistribute it and/or modify
11 # it under the terms of the GNU General Public License as published by
12 # the Free Software Foundation; version 2 of the License. A copy of the
13 # GNU General Public License can be found in the file COPYING.
14 # --- T2-COPYRIGHT-NOTE-END ---
16 . misc/output/terminal
21 for x in $( ls misc/output ); do
22 if [ -f misc/output/$x/functions.in ]; then
23 eval "y=\$SDECFG_OUTPUT_$( echo $x | tr a-z A-Z )"
25 . misc/output/$x/functions.in
31 while read -r type data; do
32 # always output to the terminal
33 for plugin in terminal $plugins; do
34 eval "echo_${type}_${plugin} $data"
40 if [ -z "$SDE_OUPUT_PLUGIN_PROC_ACTIVE" ]; then
41 export SDE_OUPUT_PLUGIN_PROC_ACTIVE=1
43 # since the output plugin's stdin is the pipe, we help it out
44 # with the columns for pretty printing output
45 [ "${columns:=$COLUMNS}" ] || columns="$( stty size 2> /dev/null | cut -d' ' -f2 )"
46 [ "$columns" ] || columns=80
47 exec 199> >( output_proc $columns )
51 local request="$1" tag ; shift
54 # add each argument, seperated in quotes, after newlines and
55 # tick quotes got escaped
60 request="$request \$'$tag'"
66 echo_header() { echo_sched header "$@" ; }
67 echo_status() { echo_sched status "$@" ; }
68 echo_warning() { echo_sched warning "$@" ; }
69 echo_error() { echo_sched error "$@" ; }
70 echo_pkg_deny() { echo_sched pkg_deny "$@" ; }
71 echo_pkg_start() { echo_sched pkg_start "$@" ; }
72 echo_pkg_finish() { echo_sched pkg_finish "$@" ; }
73 echo_pkg_abort() { echo_sched pkg_abort "$@" ; }
74 echo_errorquote() { echo_sched errorquote "$@" ; }