Wish (Unix shell)

Last updated
Wish
Original author(s) Mary Gray
Developer(s) Tcl Core Team and Maintainers
Initial releaseMay 20, 1988;33 years ago (1988-05-20)
Stable release
8.6.10 / November 21, 2019;20 months ago (2019-11-21)
Operating system Cross-platform
Type Unix shell
License BSD License
Website sourceforge.net/projects/tcl/files/Tcl/

wish (Windowing Shell) is a Tcl interpreter extended with Tk commands [1] , available for Unix-like operating systems supporting the X Window System, as well as macOS, Microsoft Windows [2] [3] , and Android. [4] It provides developers the ability to create GUI widgets using the Tk toolkit and the Tcl programming language. [5] [6]

Contents

wish is open-source under the BSD License, and is currently part of the Tcl/Tk programming suite.[ citation needed ]

Usage

wish can be run without parameters. Then the % prompt is displayed and the interpreter awaits for commands entered interactively by the user. An empty window is opened in which the widgets created by user commands are displayed. This mode is suitable for experimenting.

More often wish is run with a name of a file containing a Tcl/Tk script as a parameter. It is also possible to run directly Tcl/Tk scripts; in Unix using the shebang construction; in Windows by associating the .tcl extension with the wish program.

See also

Related Research Articles

KornShell

KornShell (ksh) is a Unix shell which was developed by David Korn at Bell Labs in the early 1980s and announced at USENIX on July 14, 1983. The initial development was based on Bourne shell source code. Other early contributors were Bell Labs developers Mike Veach and Pat Sullivan, who wrote the Emacs and vi-style line editing modes' code, respectively. KornShell is backward-compatible with the Bourne shell and includes many features of the C shell, inspired by the requests of Bell Labs users.

Shell script Script written for the shell, or command line interpreter, of an operating system

A shell script is a computer program designed to be run by the Unix shell, a command-line interpreter. The various dialects of shell scripts are considered to be scripting languages. Typical operations performed by shell scripts include file manipulation, program execution, and printing text. A script which sets up the environment, runs the program, and does any necessary cleanup, logging, etc. is called a wrapper.

Unix shell Command-line interpreter for Unix operating system

A Unix shell is a command-line interpreter or shell that provides a command line user interface for Unix-like operating systems. The shell is both an interactive command language and a scripting language, and is used by the operating system to control the execution of the system using shell scripts.

In computing, cross-platform software is computer software that is implemented on multiple computing platforms. Cross-platform software may be divided into two types; one requires individual building or compilation for each platform that it supports, and the other one can be directly run on any platform without special preparation, e.g., software written in an interpreted language or pre-compiled portable bytecode for which the interpreters or run-time packages are common or standard components of all platforms.

cd (command)

The cd command, also known as chdir, is a command-line shell command used to change the current working directory in various operating systems. It can be used in shell scripts and batch files.

Windows Script Host

The Microsoft Windows Script Host (WSH) is an automation technology for Microsoft Windows operating systems that provides scripting abilities comparable to batch files, but with a wider range of supported features. This tool was first provided on Windows 95 after Build 950a on the installation discs as an optional installation configurable and installable by means of the Control Panel, and then a standard component of Windows 98 and subsequent and Windows NT 4.0 Build 1381 and by means of Service Pack 4. The WSH is also a means of automation for Internet Explorer via the installed WSH engines from IE Version 3.0 onwards; at this time VBScript became means of automation for Microsoft Outlook 97. The WSH is also an optional install provided with a VBScript and JScript engine for Windows CE 3.0 and following and some third-party engines including Rexx and other forms of Basic are also available.

An environment variable is a dynamic-named value that can affect the way running processes will behave on a computer. They are part of the environment in which a process runs. For example, a running process can query the value of the TEMP environment variable to discover a suitable location to store temporary files, or the HOME or USERPROFILE variable to find the directory structure owned by the user running the process.

Originally, a one-liner program was textual input to the command-line of an operating system shell that performs some function in just one line of input. The one-liner can be

Comparison of command shells Wikimedia list article

A command shell is a command-line interface to interact with and manipulate an computer's operating system.

Shell (computing) Computer program which exposes an operating systems services to a human user or other program

In computing, a shell is a computer program which exposes an operating system's services to a human user or other program. In general, operating system shells use either a command-line interface (CLI) or graphical user interface (GUI), depending on a computer's role and particular operation. It is named a shell because it is the outermost layer around the operating system.

Tkinter is a Python binding to the Tk GUI toolkit. It is the standard Python interface to the Tk GUI toolkit, and is Python's de facto standard GUI. Tkinter is included with standard Linux, Microsoft Windows and Mac OS X installs of Python.

In computing, a shebang is the character sequence consisting of the characters number sign and exclamation mark at the beginning of a script. It is also called sha-bang, hashbang, pound-bang, or hash-pling.

MKS Toolkit is a software package produced and maintained by PTC that provides a Unix-like environment for scripting, connectivity and porting Unix and Linux software to Microsoft Windows. It was originally created for MS-DOS, and OS/2 versions were released up to version 4.4. Several editions of each version, such as MKS Toolkit for developers, power users, enterprise developers and interoperability are available, with the enterprise developer edition being the most complete.

Tk (software) GUI toolkit or framework

Tk is a free and open-source, cross-platform widget toolkit that provides a library of basic elements of GUI widgets for building a graphical user interface (GUI) in many programming languages.

PowerShell Cross-platform command-line interface and scripting language for system and network administration

PowerShell is a task automation and configuration management framework from Microsoft, consisting of a command-line shell and the associated scripting language. Initially a Windows component only, known as Windows PowerShell, it was made open-source and cross-platform on 18 August 2016 with the introduction of PowerShell Core. The former is built on the .NET Framework, the latter on .NET Core.

A batch file is a script file in DOS, OS/2 and Microsoft Windows. It consists of a series of commands to be executed by the command-line interpreter, stored in a plain text file. A batch file may contain any command the interpreter accepts interactively and use constructs that enable conditional branching and looping within the batch file, such as IF, FOR, and GOTO labels. The term "batch" is from batch processing, meaning "non-interactive execution", though a batch file may not process a batch of multiple data.

A scripting language or script language is a programming language for a runtime system that automates the execution of tasks that would otherwise be performed individually by a human operator. Scripting languages are usually interpreted at runtime rather than compiled.

Command-line interface Type of computer interface based on entering text commands and viewing text output

A command-line interface (CLI) processes commands to a computer program in the form of lines of text. The program which handles the interface is called a command-line interpreter or command-line processor. Operating systems implement a command-line interface in a shell for interactive access to operating system functions or services. Such access was primarily provided to users by computer terminals starting in the mid-1960s, and continued to be used throughout the 1970s and 1980s on VAX/VMS, Unix systems and personal computer systems including DOS, CP/M and Apple DOS.

Tcl is a high-level, general-purpose, interpreted, dynamic programming language. It was designed with the goal of being very simple but powerful. Tcl casts everything into the mold of a command, even programming constructs like variable assignment and procedure definition. Tcl supports multiple programming paradigms, including object-oriented, imperative and functional programming or procedural styles.

References

  1. Welch, Brent B.; Jones, Ken; Hobbs, Jeffrey (2003). Practical Programming in Tcl and Tk (4th ed.). Upper Saddle River: Pearson Education, Inc. - Prentice Hall PTTR. p. 25. ISBN   0-13-038560-3.
  2. "ActiveTcl". ActiveState.
  3. "Cygwin". 2017-05-04.
  4. "AndroWish". 2013-12-04.
  5. Gray, Mary (May 20, 1988), Wish A Window-Based Shell for X (PDF), Computer Science Department, University of California, Berkeley, retrieved November 8, 2016
  6. Flynt, Clif (2012-01-17). Tcl/Tk: A Developer's Guide (3rd ed.). Elsevier: Morgan Kaufman. p. 17. ISBN   978-0-12-384717-1.