User Tools

Site Tools


# $EPIC: set_log_rewrite.txt,v 1.2 2006/08/20 13:51:17 sthalik Exp $


set(4) log_rewrite


If this /SET is defined (by default, it is un-set), then every time a LOGICAL line of output is about to be sent to a window, the /SET value is expanded, and the result of that expansion is substituted for the original text. The expansion is parsed in the context that: $0 The window refnum the output is going to $1- The text itself.


This would cause all output to all windows to be preceded in the logfile by +++


This would return proceed all output to all logfiles with the output of the user defined function $myfunc() called with the window number.

/SET LOG_REWRITE $myfunc($0) $1-


When changing /set output_rewrite inside of an alias, please remember that $'s are expanded before the /set is called, and so things like $1- or $myfunc($0) would be expanded at the /set time and not at the rewrite time. Make sure to double up your $$'s in such cases!


This provides an effective way to alter data as it is written to logfiles.

set_log_rewrite.txt · Last modified: 2006/08/29 16:08 (external edit)