scripting+language

= =‍[|Scripting language From Wikipedia, the free encyclopedia]=
 * || = [[image:http://www.wikispaces.com/i/c.gif width="16" height="16" caption="remove from favorites"]] [[image:http://www.wikispaces.com/i/c.gif width="16" height="16" caption="add to favorites"]]Scripting Language
 * || = [[image:http://www.wikispaces.com/i/c.gif width="16" height="16" caption="remove from favorites"]] [[image:http://www.wikispaces.com/i/c.gif width="16" height="16" caption="add to favorites"]]Scripting Language

A scripting language or **script language** is a [|programming language] that supports the writing of **scripts**, programs written for a [|software environment] that [|automate] the [|execution] of tasks which could alternatively be executed one-by-one by a human operator. Environments that can be automated through scripting include [|software applications], [|web pages] within a [|web browser], the [|shells] of [|operating systems] (OS), and several [|general purpose] and [|domain-specific languages] such as those for [|embedded systems]. Scripting is usually a property of the primary implementations of a language, rather than a language per se, although many languages are not very suited to this kind of implementation. For example, [|C++] interpreters do exist, but C++ is generally not considered a scripting language for two reasons: these implementations are rarely used, and the time required to write program in C++ would be far greater than the time required to write an equivalent script in a language like [|Python]. Typically, a scripting language is characterised by the following properties: Scripts can be written and executed "on-the-fly", without explicit [|compile] and [|link] steps; they are typically created or modified by the person executing them.[|[][|1][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-1]|]]] A scripting language is usually [|interpreted] from source code or [|bytecode].[|[][|2][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-2]|]]] By contrast, the software environment the scripts are written for is typically written in a [|compiled language] and distributed in [|machine code] form; the user may not have access to its [|source code], let alone be able to modify it. The spectrum of scripting languages ranges from very small and highly [|domain-specific languages] to [|general-purpose programming languages]. The term **script** is typically reserved for small programs (up to a few thousand lines of code).|| ==‍Contents== [[|hide]]
 * Ease of use. Scripting languages are intended to be very fast to pick up and author programs in. This generally implies relatively simple [|syntax] and [|semantics].
 * OS facilities - especially [|filesystem] and related, built in with easy interfaces. Scripting is usually aimed at [|desktops], limiting the portability needs of the pre-built libraries.
 * Interpreted from source code - to give the fastest turnaround from script to execution. On a desktop, the performance of even a slow interpreter is often non-problematic. In comparison, non-scripting languages intended for large programs are often pre[|compiled] in at least some sense for superior performance.
 * Relatively loose structure. It would be difficult to use [|Java] as a scripting language due to the rules about which classes exist in which files - contrast to Python, where it's possible to simply define some functions in a file.
 * [|1] [|History]
 * [|2] [|Types of scripting languages]
 * [|2.1] [|Job control languages and shells]
 * [|2.2] [|GUI scripting]
 * [|2.3] [|Application-specific languages]
 * [|2.4] [|Text processing languages]
 * [|2.5] [|General-purpose dynamic languages]
 * [|2.6] [|Extension/embeddable languages]
 * [|3] [|Market analysis]
 * [|4] [|See also]
 * [|5] [|References]
 * [|6] [|External links] ||

‍ [[|edit]] History
Early [|mainframe computers] (in the 1950s) were non-interactive, instead using [|batch processing]. IBM's [|Job Control Language] (JCL) is the archetype of languages used to control batch processing.[|[][|3][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-3]|]]] The first interactive [|shells] were developed in the 1960s to enable remote operation of the first [|time-sharing] systems, and these used [|shell scripts], which controlled running computer programs within a computer program, the shell. [|Calvin Mooers] in his [|TRAC] language is generally credited with inventing //command substitution//, the ability to imbed commands in scripts that when interpreted insert a character string into the script.[|[][|4][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-4]|]]] [|Multics] calls these //active functions//.[|[][|5][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-5]|]]] [|Louis Pouzin] wrote an early processor for command scripts called RUNCOM for [|CTSS] around 1964. [|Stuart Madnick] at MIT wrote a scripting language for IBM's [|CP/CMS] in 1966. He originally called this processor COMMAND, later named [|EXEC].[|[][|6][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-6]|]]] Multics included an offshoot of CTSS RUNCOM, also called RUNCOM.[|[][|7][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-7]|]]] Languages such as [|Tcl] and [|Lua] were specifically designed as general purpose scripting languages that could be embedded in any application. Other languages such as [|Visual Basic for Applications] (VBA) provided strong integration with the automation facilities of an underlying system. Embedding of such general purpose scripting languages instead of developing a new language for each application also had obvious benefits, relieving the application developer of the need to code a language translator from scratch and allowing the user to apply skills learned elsewhere. Some software incorporates several different scripting languages. Modern [|web browsers] typically provide a language for writing extensions to the browser itself, and several standard embedded languages for controlling the browser, including [|JavaScript] (a dialect of [|ECMAScript]) or [|XUL]. ==‍ [[|edit]] Types of scripting languages == ===‍ [[|edit]] Job control languages and shells === Main article: [|Shell script] A major class of scripting languages has grown out of the automation of job control, which relates to starting and controlling the behavior of system programs. (In this sense, one might think of shells as being descendants of IBM's JCL, or [|Job Control Language], which was used for exactly this purpose.) Many of these languages' interpreters double as [|command-line interpreters] such as the [|Unix shell] or the MS-DOS [|COMMAND.COM]. Others, such as [|AppleScript] offer the use of English-like commands to build scripts. ===‍ [[|edit]] GUI scripting === With the advent of graphical user interfaces, a specialized kind of scripting language emerged for controlling a computer. These languages interact with the same graphic windows, menus, buttons, and so on that a human user would. They do this by simulating the actions of a user. These languages are typically used to automate user actions. Such languages are also called "[|macros]" when control is through simulated key presses or mouse clicks. These languages could in principle be used to control any GUI application; but, in practice their use is limited because their use needs support from the application and from the [|operating system]. There are a few exceptions to this limitation. Some GUI scripting languages are based on recognizing graphical objects from their display screen [|pixels]. These GUI scripting languages do not depend on support from the operating system or application. ===‍ [[|edit]] Application-specific languages === Many large application programs include an idiomatic scripting language tailored to the needs of the application user. Likewise, many [|computer game] systems use a custom scripting language to express the programmed actions of [|non-player characters] and the game environment. Languages of this sort are designed for a single application; and, while they may superficially resemble a specific general-purpose language (e.g. [|QuakeC], modeled after C), they have custom features that distinguish them. [|Emacs Lisp], while a fully formed and capable dialect of [|Lisp], contains many special features that make it most useful for extending the editing functions of Emacs. An application-specific scripting language can be viewed as a [|domain-specific programming language] specialized to a single application. ===‍ [[|edit]] Text processing languages === The processing of text-based records is one of the oldest uses of scripting languages. Scripts written for the [|Unix] tools [|AWK], [|sed], and [|grep] automate tasks that involve text files, for example, configuration and log files. [|Perl] was originally designed to overcome limitations of these tools and has grown to be one of the most widespread general purpose languages. ===‍ [[|edit]] General-purpose dynamic languages === See also: [|Dynamic programming language] Some languages, such as [|Perl], began as scripting languages[|[][|8][[[|http://en.wikipedia.org/wiki/Scripting_languages#cite_note-sheppard00-8]|]]] but were developed into programming languages suitable for broader purposes. Other similar languages – frequently interpreted, memory-managed, or [|dynamic] – have been described as "scripting languages" for these similarities, even if they are more commonly used for applications programming. They are usually //not// called "scripting languages" by their own users. ===‍ [[|edit]] Extension/embeddable languages === A number of languages have been designed for the purpose of replacing application-specific scripting languages by being embeddable in application programs. The application programmer (working in C or another systems language) includes "hooks" where the scripting language can control the application. These languages may be technically equivalent to an application-specific extension language but when an application embeds a "common" language, the user gets the advantage of being able to transfer skills from application to application. JavaScript began as and primarily still is a language for scripting inside [|web browsers]; however, the standardization of the language as [|ECMAScript] has made it popular as a general purpose embeddable language. In particular, the [|Mozilla] implementation [|SpiderMonkey] is embedded in several environments such as the [|Yahoo! Widget Engine]. Other applications embedding ECMAScript implementations include the [|Adobe] products [|Adobe Flash] ([|ActionScript]) and [|Adobe Acrobat] (for scripting [|PDF] files). [|Tcl] was created as an extension language but has come to be used more frequently as a general purpose language in roles similar to [|Python], [|Perl], and [|Ruby]. On the other hand, [|Rexx] was originally created as a job control language, but is widely used as an extension language as well as a general purpose language. Other complex and task-oriented applications may incorporate and expose an embedded programming language to allow their users more control and give them more functionality than can be available through a user interface, no matter how sophisticated. For example, [|Autodesk Maya] 3D authoring tools embed the [|MEL] scripting language, or [|Blender] which has [|Python] to fill this role. Some other types of applications that need faster feature addition or tweak-and-run cycles (e.g. [|game engines]) also use an embedded language. During the development, this allows them to prototype features faster and tweak more freely, without the need for the user to have intimate knowledge of the inner workings of the application or to rebuild it after each tweak (which can take a significant amount of time.) The scripting languages used for this purpose range from the more common and more famous [|Lua] and [|Python] to lesser-known ones such as AngelScript and [|Squirrel]. [|Ch] is another C compatible scripting option for the industry to embed into C/C++ application programs.