Windows PowerShell 1.0 Commands and Aliases
Windows PowerShell contains a wide range of built-in commands which which can be used either in the interactive shell environment, or within cmdlet scripts. In addition, each command also has a pre-configured alias which typically shortens the amount of typing necessary to invoke a command, and often provides access to a command via a more familiar name. For example, the Get-ChildItem command for listing the contents of a directory may also be executed using the more familiar dir alias.
In this chapter of Windows PowerShell 1.0 Essentials a summary of each command is provided, together with a table of alias to command relationships.
PowerShell 1.0 Command Summary
The following table lists the different commands provided with Windows PowerShell 1.0:
Command |
Type |
Description |
---|---|---|
Get-Command | Cmdlet | Get basic information about cmdlets and other elements of Windows PowerShell commands. |
Get-Help | Cmdlet | Display information about Windows PowerShell cmdlets. |
Get-History | Cmdlet | Get a list of the previous commands entered during the current session. |
Invoke-History | Cmdlet | Run selected commands from the session history. |
Add-History | Cmdlet | Append entries to the session history. |
ForEach-Object | Cmdlet | Perform an operation against each of a set of input objects. |
Where-Object | Cmdlet | Create a filter that controls which objects will be passed along a command pipeline. |
Set-PSDebug | Cmdlet | Turns script debugging features on and off, sets the trace level and toggles strict mode. |
Add-PSSnapin | Cmdlet | Add one or more Windows PowerShell snap-ins to the current console. |
Remove-PSSnapin | Cmdlet | Remove Windows PowerShell snap-ins from the current console. |
Get-PSSnapin | Cmdlet | Get the Windows PowerShell snap-ins on the computer. |
Export-Console | Cmdlet | Export the configuration of the current console to a file so that you can reuse or share it. |
Start-Transcript | Cmdlet | Create a record of all or part of a Windows PowerShell session in a text file. |
Stop-Transcript | Cmdlet | Stop a transcript. |
Add-Content | Cmdlet | Add content to the specified item(s). |
Clear-Content | Cmdlet | Delete the contents of a item, such as deleting the text from a file, but does not delete the item. |
Clear-ItemProperty | Cmdlet | Delete the value of a property but it does not delete the property. |
Join-Path | Cmdlet | Combines a path and child-path into a single path. The provider supplies the path delimiters. |
Convert-Path | Cmdlet | Convert a path from a Windows PowerShell path to a Windows PowerShell provider path. |
Copy-ItemProperty | Cmdlet | Copy a property and value from a specified location to another location. |
Get-EventLog | Cmdlet | Get information about local event logs or the entries stored in those event logs. |
Get-ChildItem | Cmdlet | Get the items and child items in one or more specified locations. |
Get-Content | Cmdlet | Get the content of the item at the specified location. |
Get-ItemProperty | Cmdlet | Retrieve the properties of a specified item. |
Get-WmiObject | Cmdlet | Get instances of WMI classes or information about available classes. |
Move-ItemProperty | Cmdlet | Move a property from one location to another. |
Get-Location | Cmdlet | Get information about the current working location. |
Set-Location | Cmdlet | Set the current working location to a specified location. |
Push-Location | Cmdlet | Push the current location onto the stack. |
Pop-Location | Cmdlet | Changes the current location to the location most recently pushed onto the stack. You can pop the location from the default stack or from a stack that you create by using Push-Location. |
New-PSDrive | Cmdlet | Install a new Windows PowerShell drive. |
Remove-PSDrive | Cmdlet | Remove a Windows PowerShell drive from its location. |
Get-PSDrive | Cmdlet | Get information about Windows PowerShell drives. |
Get-Item | Cmdlet | Get the item at the specified location. |
New-Item | Cmdlet | Create a new item in a namespace. |
Set-Item | Cmdlet | Change the value of an item to the value specified in the command. |
Remove-Item | Cmdlet | Delete the specified items. |
Move-Item | Cmdlet | Move an item from one location to another. |
Rename-Item | Cmdlet | Rename an item in a Windows PowerShell provider namespace. |
Copy-Item | Cmdlet | Copy an item from one location to another within a namespace. |
Clear-Item | Cmdlet | Delete the contents of an item, but does not delete the item. |
Invoke-Item | Cmdlet | Invoke the provider-specific default action on the specified item. |
Get-PSProvider | Cmdlet | Get information about the specified Windows PowerShell provider. |
New-ItemProperty | Cmdlet | Set a new property of an item at a location. |
Split-Path | Cmdlet | Return the specified part of a path. |
Test-Path | Cmdlet | Determine whether all elements of a path exist. |
Get-Process | Cmdlet | Get the processes that are running on the local computer. |
Stop-Process | Cmdlet | Stop one or more running processes. |
Remove-ItemProperty | Cmdlet | Delete the property and its value from an item. |
Rename-ItemProperty | Cmdlet | Rename a property of an item. |
Resolve-Path | Cmdlet | Resolve the wildcard characters in a path and displays the path contents. |
Get-Service | Cmdlet | Get the services on the local computer. |
Stop-Service | Cmdlet | Stop one or more running services. |
Start-Service | Cmdlet | Start one or more stopped services. |
Suspend-Service | Cmdlet | Suspend (pauses) one or more running services. |
Resume-Service | Cmdlet | Resumes one or more suspended (paused) services. |
Restart-Service | Cmdlet | Stop and then start one or more services. |
Set-Service | Cmdlet | Change the display name, description, or starting mode of a service. |
New-Service | Cmdlet | Create a new entry for a Windows Service in the registry and the Service Database. |
Set-Content | Cmdlet | Write or replaces the content in an item with new content. |
Set-ItemProperty | Cmdlet | Set the value of a property at the specified location. |
Get-Acl | Cmdlet | Get the security descriptor for a resource, such as a file or registry key. |
Set-Acl | Cmdlet | Change the security descriptor of a specified resource, such as a file or a registry key. |
Get-PfxCertificate | Cmdlet | Get information about .pfx certificate files on the computer. |
Get-Credential | Cmdlet | Get a credential object based on a user name and password. |
Get-ExecutionPolicy | Cmdlet | Get the current execution policy for the shell. |
Set-ExecutionPolicy | Cmdlet | Change the user preference for the execution policy of the shell. |
Get-AuthenticodeSignature | Cmdlet | Get information about the Authenticode signature in a file. |
Set-AuthenticodeSignature | Cmdlet | Use an authenticode signature to sign a Windows PowerShell script or other file. |
ConvertFrom-SecureString | Cmdlet | Convert a secure string into an encrypted standard string. |
ConvertTo-SecureString | Cmdlet | Convert encrypted standard strings to secure strings. It can also convert plain text to secure strings. It is used with ConvertFrom-SecureString and Read-Host. |
Format-List | Cmdlet | Format the output as a list of properties in which each property appears on a new line. |
Format-Custom | Cmdlet | Use a customized view to format the output. |
Format-Table | Cmdlet | Format the output as a table. |
Format-Wide | Cmdlet | Format objects as a wide table that displays only one property of each object. |
Out-Null | Cmdlet | Delete output instead of sending it to the console. |
Out-Default | Cmdlet | Send the output to the default formatter and the default output cmdlet. Has no effect on the formatting or output and is provided as a placeholder that lets you write your own Out-Default function or cmdlet. |
Out-Host | Cmdlet | Send output to the command line. |
Out-File | Cmdlet | Send output to a file. |
Out-Printer | Cmdlet | Send output to a printer. |
Out-String | Cmdlet | Send objects to the host as a series of strings. |
Add-Member | Cmdlet | Add a user-defined custom member to an instance of a Windows PowerShell object. |
Compare-Object | Cmdlet | Compare two sets of objects. |
ConvertTo-Html | Cmdlet | Create an HTML page that represents an object or a set of objects. |
Export-Csv | Cmdlet | Create a comma-separated values (CSV) file that represents the input objects. |
Import-Csv | Cmdlet | Imports comma-separated value (CSV) files in the format produced by the Export-CSV cmdlet and returns objects that correspond to the objects represented in that CSV file. |
Export-Alias | Cmdlet | Export information about currently-defined aliases to a file. |
Invoke-Expression | Cmdlet | Run a Windows PowerShell expression that is provided in the form of a string. |
Get-Alias | Cmdlet | Get the aliases for the current session. |
Get-Culture | Cmdlet | Get information about the regional settings on a computer. |
Get-Date | Cmdlet | Get the current date and time. |
Get-Host | Cmdlet | Get a reference to the current console host object. Display Windows Powershell version and regional information by default. |
Get-Member | Cmdlet | Get information about objects or collections of objects. |
Get-UICulture | Cmdlet | Get information about the current user interface culture for Windows PowerShell. |
Get-Unique | Cmdlet | Return the unique items from a sorted list. |
Import-Alias | Cmdlet | Import an alias list from a file. |
Select-String | Cmdlet | Identify patterns in strings. |
Measure-Object | Cmdlet | Measure characteristics of objects and their properties. |
New-Alias | Cmdlet | Create a new alias. |
New-TimeSpan | Cmdlet | Create a TimeSpan object. |
Read-Host | Cmdlet | Read a line of input from the console. |
Set-Alias | Cmdlet | Create or changes an alias (alternate name) for a cmdlet or other command element in the current Windows PowerShell session. |
Set-Date | Cmdlet | Change the system time on the computer to a time that you specify. |
Start-Sleep | Cmdlet | Suspend shell, script, or runspace activity for the specified period of time. |
Tee-Object | Cmdlet | Pipe object input to a file or variable, then passes the input along the pipeline. |
Measure-Command | Cmdlet | Measure the time it takes to run script blocks and cmdlets. |
Update-TypeData | Cmdlet | Update the current extended type configuration by reloading the *.types.ps1xml files into memory. |
Update-FormatData | Cmdlet | Update and appends format data files. |
Write-Host | Cmdlet | Display objects by using the host user interface |
Write-Progress | Cmdlet | Display a progress bar within a Windows PowerShell command window. |
New-Object | Cmdlet | Create an instance of a .Net or COM object. |
Select-Object | Cmdlet | Selects specified properties of an object or set of objects. It can also select unique objects from an array of objects or it can select a specified number of objects from the beginning or end of an array of objects. |
Group-Object | Cmdlet | Groups objects that contain the same value for specified properties. |
Sort-Object | Cmdlet | Sorts objects by property values. |
Get-Variable | Cmdlet | Get the variables in the current console. |
New-Variable | Cmdlet | Create a new variable. |
Set-Variable | Cmdlet | Set the value of a variable. Create the variable if one with the requested name does not exist. |
Remove-Variable | Cmdlet | Delete a variable and its value. |
Clear-Variable | Cmdlet | Delete the value of a variable. |
Export-Clixml | Cmdlet | Create an XML-based representation of an object or objects and stores it in a file. |
Import-Clixml | Cmdlet | Import a CLIXML file and creates corresponding objects within Windows PowerShell. |
Write-Debug | Cmdlet | Write a debug message to the host display. |
Write-Verbose | Cmdlet | Write a string to the verbose display of the host. |
Write-Warning | Cmdlet | Write a warning message. |
Write-Error | Cmdlet | Write an object to the error pipeline. |
Write-Output | Cmdlet | Write objects to the success pipeline. |
Get-TraceSource | Cmdlet | Get the Windows PowerShell components that are instrumented for tracing. |
Set-TraceSource | Cmdlet | Configures, starts, and stops a trace of Windows PowerShell components. |
Trace-Command | Cmdlet | The Trace-Command cmdlet configures and starts a trace of the specified expression or command. |
Alias | Provider | Provides access to the Windows PowerShell aliases and the values that they represent. |
Environment | Provider | Provides access to the Windows environment variables. |
FileSystem | Provider | The PowerShell Provider for accessing files and directories from within the Windows PowerShell. |
Function | Provider | Provides access to the functions defined in Windows PowerShell. |
Registry | Provider | Provides access to the system registry keys and values from within Windows PowerShell. |
Variable | Provider | Provides access to the Windows PowerShell variables and their values. |
Certificate | Provider | Provides access to X509 certificate stores and certificates from within Windows PowerShell. |