tcl_prompt2

When tclsh is invoked interactively, it normally does not prompt when a newline is typed but the current command is not yet complete; if tcl_prompt2 is set then its value is executed to create a prompt that can remind the user to complete the current command.

If you have a useful script for tcl_prompt2, perhaps you would consider sharing it with us?

Note: remember that anything output in the script will appear - even newlines. So if you want the prompt to appear at the beginning of the line to continue, and you want a space between the prompt and the input area, you will want to account for this in the script. For example, perhaps one might want to use

% set tcl_prompt2 {puts -nonewline ">> "}
% puts -nonewline ">> "
% set abc abc\
>> $

(where $ represents my input cursor)

See also: