Windows PowerShell is
MicrosoftMicrosoft Corporation is an American public multinational corporation headquartered in Redmond, Washington, USA that develops, manufactures, licenses, and supports a wide range of products and services predominantly related to computing through its various product divisions...
's task automation framework, consisting of a
command-lineA command-line interface is a mechanism for interacting with a computer operating system or software by typing commands to perform specific tasks...
shellA shell is a piece of software that provides an interface for users of an operating system which provides access to the services of a kernel. However, the term is also applied very loosely to applications and may include any software that is "built around" a particular component, such as web...
and associated
scripting languageA scripting language, script language, or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the...
built on top of, and integrated with the
.NET FrameworkThe .NET Framework is a software framework that runs primarily on Microsoft Windows. It includes a large library and supports several programming languages which allows language interoperability...
. PowerShell provides full access to
COMComponent Object Model is a binary-interface standard for software componentry introduced by Microsoft in 1993. It is used to enable interprocess communication and dynamic object creation in a large range of programming languages...
and
WMIWindows Management Instrumentation is a set of extensions to the Windows Driver Model that provides an operating system interface through which instrumented components provide information and notification...
, enabling administrators to perform administrative tasks on both local and remote Windows systems.
In PowerShell, administrative tasks are generally performed by
cmdlets , specialized .NET
classesIn object-oriented programming, a class is a construct that is used as a blueprint to create instances of itself – referred to as class instances, class objects, instance objects or simply objects. A class defines constituent members which enable these class instances to have state and behavior...
implementing a particular operation. Sets of cmdlets may be combined together in
scripts,
executables (which are standalone applications), or by instantiating regular .NET classes (or WMI/COM Objects). These work by accessing data in different data stores, like the filesystem or
registryThe Windows Registry is a hierarchical database that stores configuration settings and options on Microsoft Windows operating systems. It contains settings for low-level operating system components as well as the applications running on the platform: the kernel, device drivers, services, SAM, user...
, which are made available to the PowerShell runtime via Windows PowerShell
providers.
Windows PowerShell also provides a hosting mechanism with which the Windows PowerShell runtime can be embedded inside other applications. These applications then leverage Windows PowerShell functionality to implement certain operations, including those exposed via the
graphical interfaceIn computing, a graphical user interface is a type of user interface that allows users to interact with electronic devices with images rather than text commands. GUIs can be used in computers, hand-held devices such as MP3 players, portable media players or gaming devices, household appliances and...
. This capability has been utilized by
Microsoft Exchange ServerMicrosoft Exchange Server is the server side of a client–server, collaborative application product developed by Microsoft. It is part of the Microsoft Servers line of server products and is used by enterprises using Microsoft infrastructure products...
2007 to expose its management functionality as PowerShell cmdlets and providers and implement the
graphicalIn computing, a graphical user interface is a type of user interface that allows users to interact with electronic devices with images rather than text commands. GUIs can be used in computers, hand-held devices such as MP3 players, portable media players or gaming devices, household appliances and...
management tools as PowerShell hosts which invoke the necessary cmdlets. Other
MicrosoftMicrosoft Corporation is an American public multinational corporation headquartered in Redmond, Washington, USA that develops, manufactures, licenses, and supports a wide range of products and services predominantly related to computing through its various product divisions...
applications including Microsoft SQL Server 2008 also expose their management interface via PowerShell cmdlets. With PowerShell, graphical interface-based management applications on Windows are layered on top of Windows PowerShell. A PowerShell scripting interface for Windows products is mandated by the Common Engineering Criteria.
Windows PowerShell includes its own extensive, console-based help, similar to
man pagesMan pages are the extensive documentation that comes preinstalled with almost all substantial Unix and Unix-like operating systems. The Unix command used to display them is man. Each page is a self-contained document.- Usage :...
in
Unix shellA Unix shell is a command-line interpreter or shell that provides a traditional user interface for the Unix operating system and for Unix-like systems...
s via the
Get-Help cmdlet.
Versions
Initially using the code name "Monad", PowerShell was first shown publicly at the Professional Developers Conference in September 2003. There are currently two versions of PowerShell supported by Microsoft.
Version 1.0 was released in 2006 for
Windows XPWindows XP is an operating system produced by Microsoft for use on personal computers, including home and business desktops, laptops and media centers. First released to computer manufacturers on August 24, 2001, it is the second most popular version of Windows, based on installed user base...
SP2/SP3,
Windows Server 2003Windows Server 2003 is a server operating system produced by Microsoft, introduced on 24 April 2003. An updated version, Windows Server 2003 R2, was released to manufacturing on 6 December 2005...
, and
Windows VistaWindows Vista is an operating system released in several variations developed by Microsoft for use on personal computers, including home and business desktops, laptops, tablet PCs, and media center PCs...
. For Windows Server 2008, it is included as an optional feature.
Version 2.0 is integrated with Windows 7 and
Windows Server 2008 R2Windows Server 2008 R2 is a server operating system produced by Microsoft. It was released to manufacturing on July 22, 2009 and launched on October 22, 2009. According to the Windows Server Team blog, the retail availability was September 14, 2009. It is built on Windows NT 6.1, the same core...
and is released for
Windows XPWindows XP is an operating system produced by Microsoft for use on personal computers, including home and business desktops, laptops and media centers. First released to computer manufacturers on August 24, 2001, it is the second most popular version of Windows, based on installed user base...
with Service Pack 3,
Windows Server 2003Windows Server 2003 is a server operating system produced by Microsoft, introduced on 24 April 2003. An updated version, Windows Server 2003 R2, was released to manufacturing on 6 December 2005...
with Service Pack 2 and
Windows VistaWindows Vista is an operating system released in several variations developed by Microsoft for use on personal computers, including home and business desktops, laptops, tablet PCs, and media center PCs...
with Service Pack 1.
Background
Every released version of Microsoft DOS and
Microsoft WindowsMicrosoft Windows is a series of operating systems produced by Microsoft.Microsoft introduced an operating environment named Windows on November 20, 1985 as an add-on to MS-DOS in response to the growing interest in graphical user interfaces . Microsoft Windows came to dominate the world's personal...
for
personal computerA personal computer is any general-purpose computer whose size, capabilities, and original sales price make it useful for individuals, and which is intended to be operated directly by an end-user with no intervening computer operator...
s has included a command-line interface tool (
shellA shell is a piece of software that provides an interface for users of an operating system which provides access to the services of a kernel. However, the term is also applied very loosely to applications and may include any software that is "built around" a particular component, such as web...
). These are
COMMAND.COMCOMMAND.COM is the filename of the default operating system shell for DOS operating systems and the default command line interpreter on Windows 95, Windows 98 and Windows Me...
(in installations relying on
MS-DOSMS-DOS is an operating system for x86-based personal computers. It was the most commonly used member of the DOS family of operating systems, and was the main operating system for IBM PC compatible personal computers during the 1980s to the mid 1990s, until it was gradually superseded by operating...
, including
Windows 9xWindows 9x is a generic term referring to a series of Microsoft Windows computer operating systems produced since 1995, which were based on the original and later modified Windows 95 kernel...
) and
cmd.exe (in
Windows NTWindows NT is a family of operating systems produced by Microsoft, the first version of which was released in July 1993. It was a powerful high-level-language-based, processor-independent, multiprocessing, multiuser operating system with features comparable to Unix. It was intended to complement...
family operating systems). These are regular command line interpreters that support a few basic commands. For other purposes, a separate
console applicationA console application is a computer program designed to be used via a text-only computer interface, such as a text terminal, the command line interface of some operating systems or the text-based interface included with most Graphical User Interface operating systems, such as the Win32 console in...
needs to be provided, to be invoked from these shells. They also include a scripting language (batch files), which can be used to automate various tasks. However, they cannot be used to automate all facets of
GUIIn computing, a graphical user interface is a type of user interface that allows users to interact with electronic devices with images rather than text commands. GUIs can be used in computers, hand-held devices such as MP3 players, portable media players or gaming devices, household appliances and...
functionality, in part because command-line equivalents of operations exposed via the graphical interface are limited, and the scripting language is elementary and does not allow the creation of complex scripts. In
Windows Server 2003Windows Server 2003 is a server operating system produced by Microsoft, introduced on 24 April 2003. An updated version, Windows Server 2003 R2, was released to manufacturing on 6 December 2005...
, the situation was improved, but scripting support was still considered unsatisfactory.
Microsoft attempted to address some of these shortcomings by introducing the
Windows Script HostThe Microsoft Windows Script Host is an automation technology for Microsoft Windows operating systems that provides scripting capabilities comparable to batch files, but with a greater range of supported features...
in 1998 with
Windows 98Windows 98 is a graphical operating system by Microsoft. It is the second major release in the Windows 9x line of operating systems. It was released to manufacturing on 15 May 1998 and to retail on 25 June 1998. Windows 98 is the successor to Windows 95. Like its predecessor, it is a hybrid...
, and its command-line based host:
cscript.exe. It integrates with the Active Script engine and allows scripts to be written in compatible languages, such as
JScriptJScript is a scripting language based on the ECMAScript standard that is used in Microsoft's Internet Explorer.JScript is implemented as a Windows Script engine. This means that it can be "plugged in" to any application that supports Windows Script, such as Internet Explorer, Active Server Pages,...
and
VBScriptVBScript is an Active Scripting language developed by Microsoft that is modeled on Visual Basic. It is designed as a “lightweight” language with a fast interpreter for use in a wide variety of Microsoft environments...
, leveraging the APIs exposed by applications via
COMComponent Object Model is a binary-interface standard for software componentry introduced by Microsoft in 1993. It is used to enable interprocess communication and dynamic object creation in a large range of programming languages...
. However, it too has its own deficiencies: it is not integrated with the shell, its documentation is not very accessible, and it quickly gained a reputation as a system vulnerability vector after several high-profile computer viruses exploited weaknesses in its security provisions. Different versions of Windows provided various special-purpose command line interpreters (such as
netshIn software, netsh, or network shell, is a utility included in Microsoft's Windows NT line of operating systems beginning with Windows 2000. It allows local or remote configuration of network devices such as the interface....
and WMIC) with their own command sets. None of them were integrated with the command shell; nor were they interoperable.
By 2002 Microsoft had started to develop a new approach to command line management, including a shell called Monad (aka Microsoft Shell or MSH). The shell and the ideas behind it were published in August 2002 in a white paper entitled Monad Manifesto. Monad was to be a new extensible command shell with a fresh design that would be capable of automating a full range of core administrative tasks. Microsoft first showed off Monad at the Professional Development Conference in Los Angeles in September 2003. A private beta program began a few months later which eventually led to a public beta program.
Microsoft published the first Monad public beta release on June 17, 2005, Beta 2 on September 11, 2005, and Beta 3 on January 10, 2006. Not much later, on April 25, 2006 Microsoft formally announced that Monad had been renamed
Windows PowerShell, positioning it as a significant part of their management technology offerings. Release Candidate 1 of PowerShell was released at the same time. A significant aspect of both the name change and the RC was that this was now a component of Windows, and not an add-on product.
Release Candidate 2 of PowerShell version 1 was released on September 26, 2006 with final Release to the web (RTW) on November 14, 2006 and announced at TechEd Barcelona. PowerShell for earlier versions of Windows was released on January 30, 2007.
The road to PowerShell version 2 began pretty much as soon as V1 shipped. There were three community technology preview (CTP) releases that Microsoft made available to the public. The last CTP release of Windows PowerShell v2.0 was made available in December 2008.
PowerShell v2.0 was completed and released to manufacturing in August 2009, as an integral part of Windows 7 and Windows Server 2008 R2. Versions of PowerShell for Windows XP, Windows Server 2003, Windows Vista and Windows Server 2008 were released in October 2009 and are available for download for both 32-bit and 64-bit platforms.
Overview
There are four kinds of commands Windows PowerShell can execute:
- 'cmdlets', which are .NET
The .NET Framework is a software framework that runs primarily on Microsoft Windows. It includes a large library and supports several programming languages which allows language interoperability...
programs, written by a developer, compiled into a dynamic-link libraryDynamic-link library , or DLL, is Microsoft's implementation of the shared library concept in the Microsoft Windows and OS/2 operating systems...
and loaded by a PowerShell script,
- PowerShell scripts (files suffixed by '.ps1'),
- PowerShell functions,
- executable
In computing, an executable file causes a computer "to perform indicated tasks according to encoded instructions," as opposed to a data file that must be parsed by a program to be meaningful. These instructions are traditionally machine code instructions for a physical CPU...
programs.
If a command is an executable program,
PowerShell.exe launches it in a separate
processIn computing, a process is an instance of a computer program that is being executed. It contains the program code and its current activity. Depending on the operating system , a process may be made up of multiple threads of execution that execute instructions concurrently.A computer program is a...
; if it is a cmdlet, it is executed in the PowerShell process. PowerShell also provides an interactive command line interface, wherein the commands can be entered and their output displayed. The user interface, based on the
Win32 consoleWin32 console is a text user interface implementation within the system of Windows API, which runs console applications. A Win32 console has a screen buffer and an input buffer, and is available both as a window or in text mode screen, with switching back and forth available via Alt-Enter...
, offers customizable
tab completionCommand line completion is a common feature of command line interpreters, in which the program automatically fills in partially typed commands....
but lacks
syntax highlightingSyntax highlighting is a feature of some text editors that display text—especially source code—in different colors and fonts according to the category of terms. This feature eases writing in a structured language such as a programming language or a markup language as both structures and...
. PowerShell also enables the creation of
aliases for cmdlets, which are textually translated by PowerShell into invocations of the original commands. PowerShell also supports both
namedIn computer programming, named parameters or keyword arguments refer to a computer language's support for function calls that clearly state the name of each parameter within the function call itself.- Overview :...
and positional
parametersIn computer programming, a parameter is a special kind of variable, used in a subroutine to refer to one of the pieces of data provided as input to the subroutine. These pieces of data are called arguments...
for commands. In executing a cmdlet, the job of binding the argument value to the parameter is done by PowerShell itself, but, for external executables, arguments are passed via the argv (or equivalent) variable array to be parsed by the executable.
Another concept used by PowerShell is that of a
pipeline. Like
Unix pipelinesIn Unix-like computer operating systems , a pipeline is the original software pipeline: a set of processes chained by their standard streams, so that the output of each process feeds directly as input to the next one. Each connection is implemented by an anonymous pipe...
, PowerShell pipelines are used to compose complex commands, allowing the output of one command to be passed as input to another. A pipeline is set up by
piping the output of one command (or pipeline) to another command, using the
| operator. But, unlike its Unix counterpart, the PowerShell pipeline is an
object pipelineIn software engineering, a pipeline consists of a chain of processing elements , arranged so that the output of each element is the input of the next. Usually some amount of buffering is provided between consecutive elements...
; that is, the data passed between cmdlets are fully
typedA type system associates a type with each computed value. By examining the flow of these values, a type system attempts to ensure or prove that no type errors can occur...
objectsIn computer science, an object is any entity that can be manipulated by the commands of a programming language, such as a value, variable, function, or data structure...
, rather than character streams. When data is piped as objects, the elements they encapsulate retain their structure and types across cmdlets, without the need for any serialization or explicit parsing of the stream, as would be the need if only character streams were shared. An object can also encapsulate certain functions that work on the contained data. These also become available to the recipient command for use. For the last cmdlet in a pipeline, PowerShell automatically pipes its output object to the
Out-Default cmdlet, which transforms the objects into a stream of format objects and then renders those to the screen.
Because all PowerShell objects are .NET objects, they share a
.ToString method, which retrieves the text representation of the data in an object. Windows PowerShell uses this method to convert an object to text. In addition, it also allows formatting definitions to be specified, so the text representation of objects may be customized by choosing which data elements to display, and how. However, in order to maintain backwards compatibility, if an external executable is used in a pipeline, it receives a text stream representing the object, and does not integrate with the PowerShell type system.
The PowerShell
Extended Type System (
ETS) is based on the .NET type system, but with extended semantics (e.g. propertySets and 3rd party extensibility) . For example, it enables the creation of different views of objects by exposing only a subset of the data fields, properties, and methods, as well as specifying custom formatting and sorting behavior. These views are mapped to the original object using
XMLExtensible Markup Language is a set of rules for encoding documents in machine-readable form. It is defined in the XML 1.0 Specification produced by the W3C, and several other related specifications, all gratis open standards....
-based configuration files.
Cmdlets
Cmdlets are specialized commands in the PowerShell environment that implement specific functions. These are the native commands in the PowerShell stack. Cmdlets follow a
-
naming pattern, such as
Get-ChildItem, helping to make them self-descriptive. Cmdlets output their results as objects, or collections thereof (including arrays), and can optionally receive input in that form, making them suitable for use as recipients in a pipeline. But, whereas PowerShell allows arrays and other collections of objects to be written to the pipeline, cmdlets always process objects individually. For collections of objects, PowerShell invokes the cmdlet on each object in the collection, in sequence.
Cmdlets are specialized .NET classes, which the PowerShell runtime instantiates and invokes when they are run. Cmdlets derive either from
Cmdlet or from
PSCmdlet, the latter being used when the cmdlet needs to interact with the PowerShell runtime. These base classes specify certain methods -
BeginProcessing, ProcessRecord and EndProcessing - which the cmdlet's implementation overrides to provide the functionality. Whenever a cmdlet is run, these methods are invoked by PowerShell in sequence, with ProcessRecord being called if it receives pipeline input. If a collection of objects is piped, the method is invoked for each object in the collection. The class implementing the Cmdlet must have one .NET attributeIn computing, an attribute is a specification that defines a property of an object, element, or file. It may also refer to or set the specific value for a given instance of such....
- CmdletAttribute - which specifies the verb and the noun that make up the name of the cmdlet. Common verbs are provided as an enumIn computer programming, an enumerated type is a data type consisting of a set of named values called elements, members or enumerators of the type. The enumerator names are usually identifiers that behave as constants in the language...
.
If a cmdlet receives either pipeline input or command-line parameter input, there must be a corresponding propertyA property, in some object-oriented programming languages, is a special sort of class member, intermediate between a field and a method. Properties are read and written like fields, but property reads and writes are translated to get and set method calls...
in the class, with a mutatorIn computer science, a mutator method is a method used to control changes to a variable.The mutator method, sometimes called a "setter", is most often used in object-oriented programming, in keeping with the principle of encapsulation...
implementation. PowerShell invokes the mutator with the parameter value or pipeline input, which is saved by the mutator implementation in class variables. These values are then referred to by the methods which implement the functionality. Properties that map to command-line parameters are marked by ParameterAttribute and are set before the call to BeginProcessing. Those which map to pipeline input are also flanked by ParameterAttribute, but with the ValueFromPipeline attribute parameter set.
The implementation of these cmdlet classes can refer to any .NETThe .NET Framework is a software framework that runs primarily on Microsoft Windows. It includes a large library and supports several programming languages which allows language interoperability...
API and may be in any .NET language. In addition, PowerShell makes certain APIs available, such as WriteObject, which is used to access PowerShell-specific functionality, such as writing resultant objects to the pipeline. Cmdlets can use .NET data access APIs directly or use the PowerShell infrastructure of PowerShell Providers, which make data stores addressable using unique pathsA path, the general form of a filename or of a directory name, specifies a unique location in a file system. A path points to a file system location by following the directory tree hierarchy expressed in a string of characters in which path components, separated by a delimiting character, represent...
. Data stores are exposed using drive letters, and hierarchies within them, addressed as directories. Windows PowerShell ships with providers for the file systemA file system is a means to organize data expected to be retained after a program terminates by providing procedures to store, retrieve and update data, as well as manage the available space on the device which contain it. A file system organizes data in an efficient manner and is tuned to the...
, registryThe Windows Registry is a hierarchical database that stores configuration settings and options on Microsoft Windows operating systems. It contains settings for low-level operating system components as well as the applications running on the platform: the kernel, device drivers, services, SAM, user...
, the certificateIn cryptography, a public key certificate is an electronic document which uses a digital signature to bind a public key with an identity — information such as the name of a person or an organization, their address, and so forth...
store, as well as the namespaces for command aliases, variables, and functions. Windows PowerShell also includes various cmdlets for managing various WindowsMicrosoft Windows is a series of operating systems produced by Microsoft.Microsoft introduced an operating environment named Windows on November 20, 1985 as an add-on to MS-DOS in response to the growing interest in graphical user interfaces . Microsoft Windows came to dominate the world's personal...
systems, including the file systemA file system is a means to organize data expected to be retained after a program terminates by providing procedures to store, retrieve and update data, as well as manage the available space on the device which contain it. A file system organizes data in an efficient manner and is tuned to the...
, or using Windows Management InstrumentationWindows Management Instrumentation is a set of extensions to the Windows Driver Model that provides an operating system interface through which instrumented components provide information and notification...
to control Windows components. Other applications can register cmdlets with PowerShell, thus allowing it to manage them, and, if they enclose any datastore (such as databases), they can add specific providers as well.
In PowerShell V2, a more portable version of Cmdlets called Modules have been added. The PowerShell V2 release notes state, "Modules allow script developers and administrators to partition and organize their Windows PowerShell code in self-contained, reusable units. Code from a module executes in its own self-contained context and does not affect the state outside of the module. Modules also enable you to define a restricted runspace environment by using a script."
Pipeline
PowerShell, like Unix/Linux based shells, implements a pipeline. This pipeline enables the output of one cmdlet to be piped as input to another cmdlet. For example, the output of the Get-Process cmdlet can be piped to the Sort-Object cmdlet (e.g. to sort the objects by handle count) and then to the Where-Object to filter any process that has, say, less than 1 MB of paged memory, then finally to the Select-Object cmdlet to select just the first 10 (i.e. the 10 processes based on handle count).
PowerShell differs from Unix/Linux in that structured .NET objects are passed between stages in the pipeline instead of typically unstructured text. Using objects eliminates the need to explicitly parse text output to extract data.
Scripting
Windows PowerShell includes a dynamically typed scripting languageA scripting language, script language, or extension language is a programming language that allows control of one or more applications. "Scripts" are distinct from the core code of the application, as they are usually written in a different language and are often created or at least modified by the...
which can implement complex operations using cmdlets imperativelyIn computer science, imperative programming is a programming paradigm that describes computation in terms of statements that change a program state...
. The scripting language supports variables, functions, branching (if-then-else), loops (whileIn most computer programming languages, a while loop is a control flow statement that allows code to be executed repeatedly based on a given boolean condition. The while loop can be thought of as a repeating if statement....
, doIn most computer programming languages, a do while loop, sometimes just called a do loop, is a control flow statement that allows code to be executed repeatedly based on a given Boolean condition. Note though that unlike most languages, Fortran's do loop is actually analogous to the for loop.The...
, forIn computer science a for loop is a programming language statement which allows code to be repeatedly executed. A for loop is classified as an iteration statement....
, and foreachFor each is a computer language idiom for traversing items in a collection. Foreach is usually used in place of a standard for statement. Unlike other for loop constructs, however, foreach loops usually maintain no explicit counter: they essentially say "do this to everything in this set",...
), structured error/exception handling and closuresIn computer science, a closure is a function together with a referencing environment for the non-local variables of that function. A closure allows a function to access variables outside its typical scope. Such a function is said to be "closed over" its free variables...
/lambda expressions, as well as integration with .NET. Variables in PowerShell scripts have names that start with $; they can be assigned any value, including the output of cmdlets. While the language is untyped, internally the variables are stored with their types, which can be either primitive typeIn computer science, primitive data type is either of the following:* a basic type is a data type provided by a programming language as a basic building block...
s or objects. Strings can be enclosed either in single quotes or in double quotes: when using double quotes, variables will be expanded even if they are inside the quotation marks. According to the variable syntax, if the path to a file is enclosed in braces preceded by a dollar sign (as in ${C:\foo.txt}), it refers to the contents of the file. If it is used as an L-valueIn computer science, a value is an expression which cannot be evaluated any further . The members of a type are the values of that type. For example, the expression "1 + 2" is not a value as it can be reduced to the expression "3"...
, anything assigned to it will be written to the file. When used as an R-valueIn computer science, a value is an expression which cannot be evaluated any further . The members of a type are the values of that type. For example, the expression "1 + 2" is not a value as it can be reduced to the expression "3"...
, it will be read from the file. If an object is assigned, it is serialized before storing it.
Object members can be accessed using . notation, as in C# syntax. PowerShell provides special variables, such as $args, which is an array of all the command line arguments passed to a function from the command line, and $_, which refers to the current object in the pipeline. PowerShell also provides arrayIn computer science, an array type is a data type that is meant to describe a collection of elements , each selected by one or more indices that can be computed at run time by the program. Such a collection is usually called an array variable, array value, or simply array...
s and associative arrayIn computer science, an associative array is an abstract data type composed of a collection of pairs, such that each possible key appears at most once in the collection....
s. The PowerShell scripting language also evaluates arithmetic expressions entered on the command line immediately, and it parses common abbreviations, such as GB, MB, and KB.
Using the function keyword, PowerShell provides for the creation of functions, which can take parameters. A common problem for people new to PowerShell is that function arguments are separated by spaces, not commas:
: Calls the function with two arguments. (These arguments may be bound to parameters declared in the function definition or accessed by position from the $args array.)
(, ): Calls the function with a single argument, a two element array.
PowerShell allows any .NET methods to be called by providing their namespaces enclosed in brackets ([]), and then using a pair of colons (::) to indicate the static method. For example,
[System.Console]::WriteLine("PowerShell").
Objects are created using the New-Object cmdlet. Calling methods of .NET objects is accomplished by using the regular . notation.
For error handling, PowerShell provides a .NET-based exception handlingException handling syntax varies between programming languages, partly to cover semantic differences but largely to fit into each language's overall syntactic structure...
mechanism. In case of errors, objects containing information about the error (Exception object) are thrown, which are caught using the trap keyword. However, the action-or-error is configurable; in case of an error, PowerShell can be configured to silently resume execution, without trapping the exception.
Scripts written using PowerShell can be made to persist across sessions in a .ps1 file. Later, either the entire script or individual functions in the script can be used. Scripts and functions are used analogously with cmdlets, in that they can be used as commands in pipelines, and parameters can be bound to them. Pipeline objects can be passed between functions, scripts, and cmdlets seamlessly. However, script execution is disabled by default and must be enabled explicitly. PowerShell scripts can be signedCode signing is the process of digitally signing executables and scripts to confirm the software author and guarantee that the code has not been altered or corrupted since it was signed by use of a cryptographic hash....
to verify their integrity, and are subject to Code Access SecurityCode Access Security , in the Microsoft .NET framework, is Microsoft's solution to prevent untrusted code from performing privileged actions. When the CLR loads an assembly it will obtain evidence for the assembly and use this to identify the code group that the assembly belongs to. A code group...
.
The PowerShell scripting language supports binary prefixIn computing, a binary prefix is a specifier or mnemonic that is prepended to the units of digital information, the bit and the byte, to indicate multiplication by a power of 2...
notation similar to the scientific notationScientific notation is a way of writing numbers that are too large or too small to be conveniently written in standard decimal notation. Scientific notation has a number of useful properties and is commonly used in calculators and by scientists, mathematicians, doctors, and engineers.In scientific...
supported by many programming languages in the C-family.
Hosting
Another use of PowerShell is being embedded in a management application, which then uses the PowerShell runtime to implement the management functionality. For this, PowerShell provides a managedManaged code is a term coined by Microsoft to identify computer program code that requires and will only execute under the "management" of a Common Language Runtime virtual machine ....
hosting API. Via the APIs, the application can instantiate a runspace (one instantiation of the PowerShell runtime), which runs in the application's processIn computing, a process is an instance of a computer program that is being executed. It contains the program code and its current activity. Depending on the operating system , a process may be made up of multiple threads of execution that execute instructions concurrently.A computer program is a...
and is exposed as a Runspace object. The state of the runspace is encased in a SessionState object. When the runspace is created, the Windows PowerShell runtime initializes the instantiation, including initializing the providers and enumerating the cmdlets, and updates the SessionState object accordingly. The Runspace then must be opened for either synchronous processing or asynchronous processing. After that it can be used to execute commands.
To execute a command, a pipeline (represented by a Pipeline object) must be created and associated with the runspace. The pipeline object is then populated with the cmdlets that make up the pipeline. For sequential operations (as in a PowerShell script), a Pipeline object is created for each statement and nested inside another Pipeline object. When a pipeline is created, Windows PowerShell invokes the pipeline processor, which resolves the cmdlets into their respective assembliesIn the .NET framework, an assembly is a compiled code library used for deployment, versioning, and security. There are two types: process assemblies and library assemblies . A process assembly represents a process that will use classes defined in library assemblies...
(the command processor) and adds a reference to them to the pipeline, and associates them with an InputPipe, Outputpipe and ErrorOutputPipe objects, to represent the connection with the pipeline. The types are verified and parameters bound using reflectionIn computer science, reflection is the process by which a computer program can observe and modify its own structure and behavior at runtime....
. Once the pipeline is set up, the host calls the Invoke method to run the commands, or its asynchronous equivalent - InvokeAsync. If the pipeline has the Write-Host cmdlet at the end of the pipeline, it writes the result onto the console screen. If not, the results are handed over to the host, which might either apply further processing or display it itself.
The hosting APIs are used by Microsoft Exchange ServerMicrosoft Exchange Server is the server side of a client–server, collaborative application product developed by Microsoft. It is part of the Microsoft Servers line of server products and is used by enterprises using Microsoft infrastructure products...
2007 to provide its management GUI. Each operation exposed in the GUI is mapped to a sequence of PowerShell commands (or pipelines). The host creates the pipeline and executes them. In fact, the interactive PowerShell console itself is a PowerShell host, which interprets the scripts entered at command line and creates the necessary Pipeline objects and invokes them.
PowerShell 2.0
Microsoft released PowerShell 2.0 with Windows 7 and Windows 2008 R2. Windows PowerShell 2.0 is installed by default on Windows Server 2008 R2Windows Server 2008 R2 is a server operating system produced by Microsoft. It was released to manufacturing on July 22, 2009 and launched on October 22, 2009. According to the Windows Server Team blog, the retail availability was September 14, 2009. It is built on Windows NT 6.1, the same core...
(except on Core installations where it is optional) and Windows 7.
For older platforms it is available via the Windows Management Framework. PowerShell V2 includes changes to the scripting language and hosting API, in addition to including more than 240 new cmdlets. It's available here
A non-exhaustive list of the new features included in PowerShell V2 is:
- PowerShell Remoting: Using WS-Management
Web Services-Management is a DMTF open standard defining a SOAP-based protocol for the management of servers, devices, applications and various Web services. The DMTF has published the standards document DSP0226 with version v1.1.0 of 2010-03-03....
, PowerShell 2.0 allows scripts and cmdlets to be invoked on a remote machine or a large set of remote machines.
- Background Jobs: Also called a PSJob, it allows a command sequence (script) or pipeline to be invoked asynchronously. Jobs can be run on the local machine or on multiple remote machines. An interactive cmdlet in a PSJob blocks the execution of the job until user input is provided.
- Transactions: Enable cmdlet and developers can perform transactional operations
In computer science, transaction processing is information processing that is divided into individual, indivisible operations, called transactions. Each transaction must succeed or fail as a complete unit; it cannot remain in an intermediate state...
. PowerShell 2.0 includes transaction cmdlets for starting, committing, and rolling back a PSTransaction as well as features to manage and direct the transaction to the participating cmdlet and provider operations. The PowerShell Registry provider supports transactions.
- ScriptCmdlets: These are cmdlets written using the PowerShell scripting language. NOTE: The preferred name for script cmdlets is now Advanced Functions.
- SteppablePipelines: This allows the user to control when the
BeginProcessing, ProcessRecord and EndProcessing functions of a cmdlet are called.
- Modules: This allows script developers and administrators to organize and partition PowerShell scripts in self-contained, reusable units. Code from a module
Modular programming is a software design technique that increases the extent to which software is composed of separate, interchangeable components called modules by breaking down program functions into modules, each of which accomplishes one function and contains everything necessary to accomplish...
executes in its own self-contained context and does not affect the state outside of the module. Modules can define a restricted runspace environment by using a script. They have a persistent state as well as public and private members.
- Data Language: A domain-specific subset of the PowerShell scripting language, that allows data definitions to be decoupled from the scripts and allow localized
In computing, internationalization and localization are means of adapting computer software to different languages, regional differences and technical requirements of a target market...
string resources to be imported into the script at runtime (Script Internationalization).
- Script Debugging: It allows breakpoint
In software development, a breakpoint is an intentional stopping or pausing place in a program, put in place for debugging purposes. It is also sometimes simply referred to as a pause....
s to be set in a PowerShell script or function. Breakpoints can be set on lines, line & columns, commands and read or write access of variables. It includes a set of cmdlets to control the breakpoints via script.
- Eventing: This feature allows listening, forwarding, and acting on management and system events. Eventing allows PowerShell hosts to be notified about state changes to their managed entities. It also enables PowerShell scripts to subscribe to ObjectEvents, PSEvents, and WmiEvents and process them synchronously and asynchronously.
- Windows PowerShell Integrated Scripting Environment (ISE): PowerShell 2.0 includes a GUI-based PowerShell host (formerly known as Graphical Windows PowerShell) that provides integrated debugger, syntax highlighting
Syntax highlighting is a feature of some text editors that display text—especially source code—in different colors and fonts according to the category of terms. This feature eases writing in a structured language such as a programming language or a markup language as both structures and...
, tab completion and up to 8 PowerShell Unicode-enabled consoles (Runspaces) in a tabbed UI, as well as the ability to run only the selected parts in a script.
- Network File Transfer: Native support for prioritized, throttled, and asynchronous transfer of files between machines using the Background Intelligent Transfer Service
Background Intelligent Transfer Service is a component of Microsoft Windows XP and later operating systems that facilitates prioritized, throttled, and asynchronous transfer of files between machines using idle network bandwidth...
(BITS).
- New Cmdlets: Including
Out-GridView, which displays tabular data in the WPFDeveloped by Microsoft, the Windows Presentation Foundation is a computer-software graphical subsystem for rendering user interfaces in Windows-based applications. WPF, previously known as "Avalon", was initially released as part of .NET Framework 3.0. Rather than relying on the older GDI...
GridViewA grid view or a datagrid is a graphical user interface element that presents a tabular view of data. A typical grid view also supports some or all of the following:* Clicking a column header to change the sort order of the grid...
object.
- New Operators:
-Split, -Join, and Splatting (@) operators.
- Exception Handling with Try-Catch-Finally: Unlike other .NET languages, this allows multiple exception types for a single catch block.
- Nestable Here-Strings: PowerShell Here-Strings have been improved and can now nest.
- Block Comments: PowerShell 2.0 supports block comments using
<# and #> as delimiters.
- New APIs: The new APIs range from handing more control over the PowerShell parser and runtime to the host, to creating and managing collection of Runspaces (RunspacePools) as well as the ability to create Restricted Runspaces which only allow a configured subset of PowerShell to be invoked. The new APIs also support participation in a Windows PowerShell managed transaction.
Comparison of cmdlets with similar commands
The following table contains a selection of the cmdlets that ship with PowerShell noting the most similar commands in other well known command line interpreters.
| PowerShell (Cmdlet) |
PowerShell (Alias) |
CMD.EXE Command Prompt is the Microsoft-supplied command-line interpreter on OS/2, Windows CE and on Windows NT-based operating systems... / COMMAND.COMCOMMAND.COM is the filename of the default operating system shell for DOS operating systems and the default command line interpreter on Windows 95, Windows 98 and Windows Me...
|
Unix shell A Unix shell is a command-line interpreter or shell that provides a traditional user interface for the Unix operating system and for Unix-like systems...
|
Description |
| Get-ChildItem |
gci, dir, ls |
dir |
ls In computing, ls is a command to list files in Unix and Unix-like operating systems. ls is specified by POSIX and the Single UNIX Specification.- History :An ls utility appeared in the original version of AT&T UNIX...
|
List all files / directories in the (current) directory |
| Get-Content |
gc, type, cat |
type In computing, type is a command in various VMS. AmigaDOS, CP/M, DOS, OS/2 and Microsoft Windows command line interpreters such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell. It is used to display the contents of specified files...
|
cat The cat command is a standard Unix program used to concatenate and display files. The name is from catenate, a synonym of concatenate.- Specification :...
|
Get the content of a file |
| Get-Command |
gcm |
help In computing, help is a command in various command line shells such as COMMAND.COM, cmd.exe, 4DOS/4NT, Windows PowerShell, Bash, Singularity shell, Python and GNU Octave. It provides online information about available commands and the shell environment. It is analogous to the Unix man command...
|
help In computing, help is a command in various command line shells such as COMMAND.COM, cmd.exe, 4DOS/4NT, Windows PowerShell, Bash, Singularity shell, Python and GNU Octave. It provides online information about available commands and the shell environment. It is analogous to the Unix man command...
|
List available commands |
| Get-Help |
help, man |
help In computing, help is a command in various command line shells such as COMMAND.COM, cmd.exe, 4DOS/4NT, Windows PowerShell, Bash, Singularity shell, Python and GNU Octave. It provides online information about available commands and the shell environment. It is analogous to the Unix man command...
|
man |
Help on commands |
| Clear-Host |
cls, clear |
cls cls is a command used by the command line interpreters COMMAND.COM and cmd.exe on DOS, OS/2 and Microsoft Windows operating systems to clear the screen or console window of commands and any output generated by them. It does not clear the user's history of commands, however...
|
clear' is a standard Unix computer operating system command which is used to clear the screen.Depending on the system, clear uses the terminfo or termcap database, as well as looking into the environment for the terminal type in order to deduce how to clear the screen. The Unix command clear takes no...
|
Clear the screen[Clear-Host is implemented as a predefined PowerShell function.] |
| Copy-Item |
cpi, copy, cp |
copy In computing, copy is a command in RT-11, RSX-11, OpenVMS, DOS, OS/2 and Microsoft Windows operating systems. The command copies computer files from one directory to another. The destination defaults to the current working directory. If more than one source file is indicated, the destination must...
|
cp cp is a UNIX command used to copy a file. Files can be copied either to the same directory or to a completely different directory, possibly on a different file system or hard disk drive. If the file is copied to the same directory, the new file must have a different name to the original; in all...
|
Copy one or several files / a whole directory tree |
| Move-Item |
mi, move, mv |
move In computing, move is a command in various DOS, OS/2 and Microsoft Windows command line interpreters such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell. It is used to move one or more files or directories from one place to another. The original file is deleted, and the new file may have...
|
mv mv is a Unix command that moves one or more files or directories from one place to another. Since it can "move" files from one filename to another, it is also used to rename files. Using mv requires the user to have write permission for the directories which the file will move between...
|
Move a file / a directory to a new location |
| Remove-Item |
ri, del, erase, rmdir, rd, rm |
del In computing, del is a command in various DOS, OS/2 and Microsoft Windows command line interpreters such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell. It is used to delete one or more files or directories from a filesystem. It is analogous to the Unix rm command... , eraseIn computing, del is a command in various DOS, OS/2 and Microsoft Windows command line interpreters such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell. It is used to delete one or more files or directories from a filesystem. It is analogous to the Unix rm command... , rmdirrmdir is a command which will remove an empty directory on a Unix, DOS, OS/2 or Microsoft Windows operating system. In Unix, Linux, and MacOS, it is case sensitive, whereas DOS, OS/2 and Windows , you can type the characters in any combination of upper case and lower case letters, and rd/rmdir... , rdrmdir is a command which will remove an empty directory on a Unix, DOS, OS/2 or Microsoft Windows operating system. In Unix, Linux, and MacOS, it is case sensitive, whereas DOS, OS/2 and Windows , you can type the characters in any combination of upper case and lower case letters, and rd/rmdir...
|
rm rm is a basic UNIX command used to remove objects such as files, directories, device nodes, symbolic links, and so on from the filesystem... , rmdir |
Delete a file / a directory |
| Rename-Item |
rni, ren, mv |
ren In computing, ren is a command in various DOS, OS/2 and Microsoft Windows command line interpreters such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell. It is used to rename files and in some implementations also directories. It is analogous to the Unix mv command... , renameIn computing, ren is a command in various DOS, OS/2 and Microsoft Windows command line interpreters such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell. It is used to rename files and in some implementations also directories. It is analogous to the Unix mv command...
|
mv mv is a Unix command that moves one or more files or directories from one place to another. Since it can "move" files from one filename to another, it is also used to rename files. Using mv requires the user to have write permission for the directories which the file will move between...
|
Rename a file / a directory |
| Get-Location |
gl, pwd |
cd |
pwd In Unix-like and some other operating systems, the pwd command is used to output the path of the current working directory.The command is a shell builtin in certain Unix shells such as sh, and bash...
|
Display the current directory/present working directory. |
| Pop-Location |
popd |
popd In computing, pushd and popd are commands in various Unix, DOS and Microsoft Windows command line interpreters such as Bash, cmd.exe, 4DOS/4NT and Windows PowerShell...
|
popd |
Change the current directory to the directory most recently pushed onto the stack |
| Push-Location |
pushd |
pushd In computing, pushd and popd are commands in various Unix, DOS and Microsoft Windows command line interpreters such as Bash, cmd.exe, 4DOS/4NT and Windows PowerShell...
|
pushd |
Push the current directory onto the stack |
| Set-Location |
sl, cd, chdir |
cd, chdir |
cd |
Change the current directory |
| Tee-Object |
tee |
n/a |
tee |
Pipe input to a file or variable, then pass the input along the pipeline |
| Write-Output |
echo, write |
echo |
echo |
Print strings, variables etc. to standard output |
| Get-Process |
gps, ps |
tlist,[Available in Windows NT4, Windows 98 Resource Kit, Windows 2000 Support Tools] tasklist[Available in Windows XP Professional Edition and later] |
ps In most Unix-like operating systems, the ps program displays the currently-running processes. A related Unix utility named top provides a real-time view of the running processes....
|
List all currently running processes |
| Stop-Process |
spps, kill |
kill, taskkill |
kill[Also used in UNIX to send a process any signal]A signal is a limited form of inter-process communication used in Unix, Unix-like, and other POSIX-compliant operating systems. Essentially it is an asynchronous notification sent to a process in order to notify it of an event that occurred. When a signal is sent to a process, the operating system... , the "Terminate" signal is merely the default |
Stop a running process |
| Select-String |
n/a |
find In computing, find is a command in the command line interpreters of DOS, OS/2 and Microsoft Windows. It is used to search for a specific text string in a file or files... , findstr |
grep grep is a command-line text-search utility originally written for Unix. The name comes from the ed command g/re/p...
|
Print lines matching a pattern |
| Set-Variable |
sv, set |
set |
env, export, set, setenv |
Set the value of a variable / create a variable |
----
Notes:
Examples
Examples are provided first using the long-form canonical syntax and then using more terse UNIX-like and DOS-like aliases that are set up in the default configuration. For a list of all aliases, use the Get-Alias Cmdlet.
- Stop all processes that begin with the letter p:
PS> Get-Process p* | Stop-Process
PS> ps p* | kill
- Find the processes that use more than 1000 MB of memory and kill them:
PS> Get-Process | Where-Object { $_.WS -gt 1000MB } | Stop-Process
PS> ps | ? { $_.WS -gt 1000MB } | kill
- Calculate the number of bytes in the files in a directory:
PS> Get-Childitem | Measure-Object -Property Length -Sum
PS> ls | measure length -s
PS> dir | measure length -s
- Determine whether a specific process is no longer running:
PS> $processToWatch = Get-Process Notepad
PS> $processToWatch.WaitForExit
PS> (ps notepad).WaitForExit
- Change the case of a string from lower to upper:
PS> 'hello, world!'.ToUpper
- Insert the string 'ABC' after the first character in the word 'string' to have the result 'sABCtring':
PS> 'string'.Insert(1, 'ABC')
- Download a specific RSS feed and show the titles of the 8 most recent entries:
PS> $rssUrl = 'http://blogs.msdn.com/powershell/rss.aspx'
PS> $blog = [xml](new-object System.Net.WebClient).DownloadString($rssUrl)
PS> $blog.rss.channel.item | select title -first 8
$x=new-object xml;$x.load('http://blogs.msdn.com/powershell/rss.aspx');$x.rss.channel.item|select title -f 8
- Sets $UserProfile to the value of the UserProfile environment variable
PS> $UserProfile = $env:UserProfile
- Call a static method of a .Net object
PS> [System.Math]::Sqrt(16)
4
- Run a command line executable with arguments:
PS> [Array]$arguments = '-h', '15', 'www.wikipedia.com'
PS> tracert $arguments
- Get the serial number of a remote computer from WMI:
PS> Get-WmiObject -ComputerName MyServer -Class Win32_BIOS | Select-Object SerialNumber
PS> gwmi -co MyServer Win32_BIOS | select SerialNumber
File extensions
- PS1 – Windows PowerShell shell script
- PS1XML – Windows PowerShell format and type definitions
- PSC1 – Windows PowerShell console file
- PSD1 – Windows PowerShell data file (for Version 2)
- PSM1 – Windows PowerShell module file (for Version 2)
Snap-ins and hosts
| Application |
Version |
Cmdlets |
Provider |
Management GUI |
| Exchange Server Microsoft Exchange Server is the server side of a client–server, collaborative application product developed by Microsoft. It is part of the Microsoft Servers line of server products and is used by enterprises using Microsoft infrastructure products...
|
2007 |
|
|
|
Windows ServerMicrosoft Windows is a series of operating systems produced by Microsoft.Microsoft introduced an operating environment named Windows on November 20, 1985 as an add-on to MS-DOS in response to the growing interest in graphical user interfaces . Microsoft Windows came to dominate the world's personal...
|
2008 |
|
|
|
Microsoft SQL ServerMicrosoft SQL Server is a relational database server, developed by Microsoft: It is a software product whose primary function is to store and retrieve data as requested by other software applications, be it those on the same computer or those running on another computer across a network...
|
2008 |
|
|
|
| System Center Operations Manager |
2007 |
|
|
|
| System Center Virtual Machine Manager System Center Virtual Machine Manager forms part of Microsoft's System Center line of management and reporting tools, alongside previously established tools such as Microsoft Operations Manager and Microsoft Systems Management Server...
|
2007 |
|
|
|
| System Center Data Protection Manager System Center Data Protection Manager is a software product from Microsoft, designed to help IT professionals manage the Windows environment. It is part of the Microsoft System Center family of products and integrates disk-to-disk and near-continuous data protection for reliable recovery of...
|
2007 |
|
|
|
| Windows Compute Cluster Server |
2007 |
|
|
|
| Microsoft Transporter Suite for Lotus Domino Lotus Domino is an IBM server product that provides enterprise-grade e-mail, collaboration capabilities, and a custom application platform. Domino began life as Lotus Notes Server, the server component of Lotus Development Corporation's client-server messaging technology. It can be used as an...
|
08.02.0012 |
|
|
|
| Microsoft PowerTools for Open XML |
1.0 |
|
|
|
| IBM WebSphere MQ |
6.0.2.2 |
|
|
|
Quest Management Shell for Active DirectoryQuest Software is a computer software manufacturer headquartered in Aliso Viejo, California. Founded in 1987, Quest develops, manufactures and supports software used by Information Technology professionals in a variety of industries...
|
1.1 |
|
|
|
| Special Operations Software Specops Command |
1.0 |
|
|
|
VMwareVMware, Inc. is a company providing virtualization software founded in 1998 and based in Palo Alto, California, USA. The company was acquired by EMC Corporation in 2004, and operates as a separate software subsidiary .... Infrastructure ToolkitVMware Infrastructure 3 is a suite of computer hardware virtualization products from VMware, Inc. . The suite includes:* VMware ESX Server version 3* VMware ESXi version 3.x...
|
1.5 |
|
|
|
Internet Information ServicesInternet Information Services – formerly called Internet Information Server – is a web server application and set of feature extension modules created by Microsoft for use with Microsoft Windows. It is the most used web server after Apache HTTP Server. IIS 7.5 supports HTTP, HTTPS,...
|
7.0 |
|
|
|
| Windows 7 Troubleshooting Center |
6.1 |
|
|
|
| Microsoft Deployment Toolkit Microsoft Deployment Toolkit is a piece of server software that permits network deployment of Microsoft Windows. It can currently distribute Windows XP, Windows Vista, Windows 7, Windows Server 2003, Windows Server 2008, and Windows Server 2008 R2...
|
2010 |
|
|
|
| NetApp Data ONTAP PowerShell Toolkit |
1.6 |
|
|
|
| JAMS Scheduler MVP Software is a company that develops the JAMS Scheduler Workload Automation and enterprise job scheduling software used to automate IT processes... - Job Access & Management System |
5.0 |
|
|
|
Alternative implementation
A project named Pash was attempted to create an open sourceThe term open source describes practices in production and development that promote access to the end product's source materials. Some consider open source a philosophy, others consider it a pragmatic methodology...
and cross-platformIn computing, cross-platform, or multi-platform, is an attribute conferred to computer software or computing methods and concepts that are implemented and inter-operate on multiple computer platforms...
implementation of PowerShell via the Mono frameworkMono, pronounced , is a free and open source project led by Xamarin to create an Ecma standard compliant .NET-compatible set of tools including, among others, a C# compiler and a Common Language Runtime....
. Pash was maintained by Igor Moochnick, written in C# and was released under the GNU General Public LicenseThe GNU General Public License is the most widely used free software license, originally written by Richard Stallman for the GNU Project....
. Pash development ceased in 2008 and is currently only partially complete.
See also
- Common Information Model
The Common Information Model is an open standard that defines how managed elements in an IT environment are represented as a common set of objects and relationships between them...
- Comparison of command shells
- Comparison of programming languages
Programming languages are used for controlling the behavior of a machine . Like natural languages, programming languages conform to rules for syntax and semantics.There are thousands of programming languages and new ones are created every year...
- Web-Based Enterprise Management
Web-Based Enterprise Management is a set of systems management technologies developed to unify the management of distributed computing environments. WBEM is based on Internet standards and Distributed Management Task Force open standards: Common Information Model infrastructure and schema,...
- Windows Script Host
The Microsoft Windows Script Host is an automation technology for Microsoft Windows operating systems that provides scripting capabilities comparable to batch files, but with a greater range of supported features...
External links