The commands listed below can be used to modify the default behavior of the XML parser or XSH2 itself. Some of the commands switch between two different modes according to a given expression (which is expected to result either in zero or non-zero value). Other commands also working as a flip-flop have their own explicit counterparts (e.g. verbose and quiet or debug and nodebug). This inconsistency is due to historical reasons.
The encoding and query-encoding settings allow to specify character encodings of user's input and XSH2's own output. This is particularly useful when you work with UTF-8 encoded documents on a console which only supports 8-bit characters.
The settings command displays current settings by means of XSH2 commands. Thus it can not only be used to review current values, but also to store them for future use, e.g. in ~/.xshrc file.
xsh> settings | cat > ~/.xshrc
turn on backup file creation
set on/off changing current document to newly open/created files
turn on/off parser's ability to fill default attribute values
display many annoying debugging messages
turn on/off serialization of empty tags
character encoding (codepage) identifier
choose output charset
turn on/off pretty-printing
turn on/off ignorable whitespace preservation
turn on/off external DTD fetching
turn off backup file creation
turn off debugging messages
list current settings using XSH2 syntax
turn on/off parser's tendency to expand entities
turn on/off transparent XInclude insertion by parser
make the parser more pedantic
declare the charset of XSH2 source files and terminal input
turn off many XSH2 messages
turn on/off parser's ability to fix broken XML
define XPath extension function (EXPERIMENTAL)
register namespace prefix to use XPath expressions
register a prefix for the XHTML namespace
register a prefix for the XSH2 namespace
switch into normal execution mode (quit test-mode)
turn on/off serialization of DTD DOCTYPE declaration
do not execute any command, only check the syntax
undefine extension function (EXPERIMENTAL)
unregister namespace prefix
turn on/off validation in XML parser
make XSH2 print many messages
sets TAB completion for axes in xpath expressions in the interactive mode
turn on/off TAB completion for xpath expressions in the interactive mode
map predefined XSH2 XPath extension functions to no or other namespace