jimsh <script>+
jimsh [<scriptfile>] +jimsh -e '<immediate-script>' +jimsh --version
From c09f838395bcc33cae854be44a2be5020fb45f87 Mon Sep 17 00:00:00 2001
From: Steve Bennett Jim Tcl v0.70 -
+ Jim Tcl v0.71 -
overview of the Jim tool command language facilities
or
-The history command is not supported
+Direct command line editing rather than the history command
+
+Expression shorthand syntax: $(…)
+
+The binary command is not supported
+Allow args to be renamed in procs
+
+Add $(…) shorthand syntax for expressions
+
+Add automatic reference variables in procs with &var syntax
+
+Support jimsh --version
+
+Additional variables in tcl_platform()
+
-$::platform_tcl() settings are now automatically determined
+platform_tcl() settings are now automatically determined
Fourth, Jim Tcl includes a command processor, jimsh, which can be
+used to run standalone Tcl scripts, or to run Tcl commands interactively. This manual page focuses primarily on the Tcl language. It describes
the language syntax and the built-in commands that will be available
in any application based on Tcl. The individual library procedures are
@@ -780,6 +827,58 @@ described in more detail in separate manual pages, one per procedure. A simple, but powerful command processor, jimsh, is part of Jim Tcl.
+It may be invoked in interactive mode as: or to process the Tcl script in a file with: It may also be invoked to execute an immediate script with: Interactive mode reads Tcl commands from standard input, evaluates
+those commands and prints the results. If jimsh is configured with line editing (it is by default) and a VT-100-compatible
+terminal is detected, Emacs-style line editing commands are available, including:
+arrow keys, ^W to erase a word, ^U to erase the line, ^R for reverse incremental search
+in history. Additionally, the h command may be used to display the command history. Command line history is automatically saved and loaded from ~/.jim_history In interactive mode, jimsh automatically runs the script ~/.jimrc at startup
+if it exists. The central data structure in Tcl is an interpreter (C type Jim_Interp).
@@ -1218,7 +1317,7 @@ sequence is replaced by the given character:
The hex digits nnnn (between one and four of them) give a unicode codepoint.
- The UTF-8 encoding of the codepoint is inserted.
+ The UTF-8 encoding of the codepoint is inserted.
NAME
jimsh <script>
+jimsh [<scriptfile>]
+jimsh -e '<immediate-script>'
+jimsh --version
CHANGES IN THIS RELEASE
+RECENT CHANGES
Changes between 0.70 and 0.71
+
+
Changes between 0.63 and 0.70
TCL INTRODUCTION
JIMSH COMMAND INTERPRETER
+jimsh
+jimsh filename
+jimsh -e "script"
+Interactive Mode
+$ jimsh
+Welcome to Jim version 0.71, Copyright (c) 2005-8 Salvatore Sanfilippo
+. info version
+0.71
+. lsort [info commands p*]
+package parray pid popen proc puts pwd
+. foreach i {a b c} {
+{> puts $i
+{> }
+a
+b
+c
+. bad
+invalid command name "bad"
+[error] . exit
+$
+INTERPRETERS
+ Reference Argument - The caller is expected to pass the name of + an existing variable. An implicit upvar 1 origname name is done + to make the variable available in the proc scope. +
+- Variable Argument - The special name args, which is + Variable Argument - The special name args, which is assigned all remaining arguments (including none). The - variable argument may only be specified once. + variable argument may only be specified once. Note that + the syntax args newname may be used to retain the special + behaviour of args with a different local name. In this case, + the variable is named newname rather than args.
expr arg
Calls the expression processor to evaluate arg, and returns the result as a string. See the section EXPRESSIONS above.
Note that Jim supports a shorthand syntax for expr as $(…) +The following two are identical.
set x [expr {3 * 2 + 1}] +set x $(3 * 2 + 1)+
Returns the length of the string in bytes. This will return - the same value as string length if UTF-8 support is not enabled, - or if the string is composed entirely of ASCII characters. - See UTF-8 AND UNICODE. + the same value as string length if UTF-8 support is not enabled, + or if the string is composed entirely of ASCII characters. + See UTF-8 AND UNICODE.
Returns a decimal string giving the number of characters in string. - If UTF-8 support is enabled, this may be different than the number of bytes. - See UTF-8 AND UNICODE + If UTF-8 support is enabled, this may be different than the number of bytes. + See UTF-8 AND UNICODE
Returns the original filename used when opening the file. - If the handle was returned from socket, the type of the - handle is returned instead. + If the handle was returned from socket, the type of the + handle is returned instead.
This variable is set by Jim as an array containing information - about the platform upon which Jim was built. + about the platform upon which Jim was built. The following is an + example of the contents of this array.
+tcl_platform(byteOrder) = littleEndian +tcl_platform(os) = Darwin +tcl_platform(platform) = unix +tcl_platform(pointerSize) = 8 +tcl_platform(threaded) = 0 +tcl_platform(wordSize) = 8+