PowerShell mode
xxxxxxxxxx
1
# Paths
2
cd c:\
3
c:\windows\calc.exe
4
5
# Number Literals
6
0 12345
7
12kb 12mb 12gB 12Tb 12PB 12L 12D 12lkb 12dtb
8
1.234 1.234e56 1. 1.e2 .2 .2e34
9
1.2MB 1.kb .1dTb 1.e1gb
10
0x1 0xabcdef 0x3tb 0xelmb
11
12
# String Literals
13
'Literal escaping'''
14
'Literal $variable'
15
"Escaping 1`""
16
"Escaping 2"""
17
"Escaped `$variable"
18
"Text, $variable and more text"
19
"Text, ${variable with spaces} and more text."
20
"Text, $($expression + 3) and more text."
21
"Text, $("interpolation $("inception")") and more text."
22
23
@"
24
Multiline
25
string
26
"@
27
# --
28
@"
29
Multiline
30
string with quotes "'
31
"@
32
# --
33
@'
34
Multiline literal
35
string with quotes "'
36
'@
37
38
# Array and Hash literals
39
@( 'a','b','c' )
40
@{ 'key': 'value' }
41
42
# Variables
43
$Variable = 5
44
$global:variable = 5
45
${Variable with spaces} = 5
46
47
# Operators
48
= += -= *= /= %=
49
++ -- .. -f * / % + -
50
-not ! -bnot
51
-split -isplit -csplit
52
-join
53
-is -isnot -as
54
-eq -ieq -ceq -ne -ine -cne
55
-gt -igt -cgt -ge -ige -cge
56
-lt -ilt -clt -le -ile -cle
57
-like -ilike -clike -notlike -inotlike -cnotlike
58
-match -imatch -cmatch -notmatch -inotmatch -cnotmatch
59
-contains -icontains -ccontains -notcontains -inotcontains -cnotcontains
60
-replace -ireplace -creplace
61
-band -bor -bxor
62
-and -or -xor
63
64
# Punctuation
65
() [] {} , : ` = ; .
66
67
# Keywords
68
elseif begin function for foreach return else trap while do data dynamicparam
69
until end break if throw param continue finally in switch exit filter from try
70
process catch
71
72
# Built-in variables
73
$$ $? $^ $_
74
$args $ConfirmPreference $ConsoleFileName $DebugPreference $Error
75
$ErrorActionPreference $ErrorView $ExecutionContext $false $FormatEnumerationLimit
76
$HOME $Host $input $MaximumAliasCount $MaximumDriveCount $MaximumErrorCount
77
$MaximumFunctionCount $MaximumHistoryCount $MaximumVariableCount $MyInvocation
78
$NestedPromptLevel $null $OutputEncoding $PID $PROFILE $ProgressPreference
79
$PSBoundParameters $PSCommandPath $PSCulture $PSDefaultParameterValues
80
$PSEmailServer $PSHOME $PSScriptRoot $PSSessionApplicationName
81
$PSSessionConfigurationName $PSSessionOption $PSUICulture $PSVersionTable $PWD
82
$ShellId $StackTrace $true $VerbosePreference $WarningPreference $WhatIfPreference
83
$true $false $null
84
85
# Built-in functions
86
A:
87
Add-Computer Add-Content Add-History Add-Member Add-PSSnapin Add-Type
88
B:
89
C:
90
Checkpoint-Computer Clear-Content Clear-EventLog Clear-History Clear-Host Clear-Item
91
Clear-ItemProperty Clear-Variable Compare-Object Complete-Transaction Connect-PSSession
92
ConvertFrom-Csv ConvertFrom-Json ConvertFrom-SecureString ConvertFrom-StringData
93
Convert-Path ConvertTo-Csv ConvertTo-Html ConvertTo-Json ConvertTo-SecureString
94
ConvertTo-Xml Copy-Item Copy-ItemProperty
95
D:
96
Debug-Process Disable-ComputerRestore Disable-PSBreakpoint Disable-PSRemoting
97
Disable-PSSessionConfiguration Disconnect-PSSession
98
E:
99
Enable-ComputerRestore Enable-PSBreakpoint Enable-PSRemoting Enable-PSSessionConfiguration
100
Enter-PSSession Exit-PSSession Export-Alias Export-Clixml Export-Console Export-Counter
101
Export-Csv Export-FormatData Export-ModuleMember Export-PSSession
102
F:
103
ForEach-Object Format-Custom Format-List Format-Table Format-Wide
104
G:
105
Get-Acl Get-Alias Get-AuthenticodeSignature Get-ChildItem Get-Command Get-ComputerRestorePoint
106
Get-Content Get-ControlPanelItem Get-Counter Get-Credential Get-Culture Get-Date
107
Get-Event Get-EventLog Get-EventSubscriber Get-ExecutionPolicy Get-FormatData Get-Help
108
Get-History Get-Host Get-HotFix Get-Item Get-ItemProperty Get-Job Get-Location Get-Member
109
Get-Module Get-PfxCertificate Get-Process Get-PSBreakpoint Get-PSCallStack Get-PSDrive
110
Get-PSProvider Get-PSSession Get-PSSessionConfiguration Get-PSSnapin Get-Random Get-Service
111
Get-TraceSource Get-Transaction Get-TypeData Get-UICulture Get-Unique Get-Variable Get-Verb
112
Get-WinEvent Get-WmiObject Group-Object
113
H:
114
help
115
I:
116
Import-Alias Import-Clixml Import-Counter Import-Csv Import-LocalizedData Import-Module
117
Import-PSSession ImportSystemModules Invoke-Command Invoke-Expression Invoke-History
118
Invoke-Item Invoke-RestMethod Invoke-WebRequest Invoke-WmiMethod
119
J:
120
Join-Path
121
K:
122
L:
123
Limit-EventLog
124
M:
125
Measure-Command Measure-Object mkdir more Move-Item Move-ItemProperty
126
N:
127
New-Alias New-Event New-EventLog New-Item New-ItemProperty New-Module New-ModuleManifest
128
New-Object New-PSDrive New-PSSession New-PSSessionConfigurationFile New-PSSessionOption
129
New-PSTransportOption New-Service New-TimeSpan New-Variable New-WebServiceProxy
130
New-WinEvent
131
O:
132
oss Out-Default Out-File Out-GridView Out-Host Out-Null Out-Printer Out-String
133
P:
134
Pause Pop-Location prompt Push-Location
135
Q:
136
R:
137
Read-Host Receive-Job Receive-PSSession Register-EngineEvent Register-ObjectEvent
138
Register-PSSessionConfiguration Register-WmiEvent Remove-Computer Remove-Event
139
Remove-EventLog Remove-Item Remove-ItemProperty Remove-Job Remove-Module
140
Remove-PSBreakpoint Remove-PSDrive Remove-PSSession Remove-PSSnapin Remove-TypeData
141
Remove-Variable Remove-WmiObject Rename-Computer Rename-Item Rename-ItemProperty
142
Reset-ComputerMachinePassword Resolve-Path Restart-Computer Restart-Service
143
Restore-Computer Resume-Job Resume-Service
144
S:
145
Save-Help Select-Object Select-String Select-Xml Send-MailMessage Set-Acl Set-Alias
146
Set-AuthenticodeSignature Set-Content Set-Date Set-ExecutionPolicy Set-Item
147
Set-ItemProperty Set-Location Set-PSBreakpoint Set-PSDebug
148
Set-PSSessionConfiguration Set-Service Set-StrictMode Set-TraceSource Set-Variable
149
Set-WmiInstance Show-Command Show-ControlPanelItem Show-EventLog Sort-Object
150
Split-Path Start-Job Start-Process Start-Service Start-Sleep Start-Transaction
151
Start-Transcript Stop-Computer Stop-Job Stop-Process Stop-Service Stop-Transcript
152
Suspend-Job Suspend-Service
153
T:
154
TabExpansion2 Tee-Object Test-ComputerSecureChannel Test-Connection
155
Test-ModuleManifest Test-Path Test-PSSessionConfigurationFile Trace-Command
156
U:
157
Unblock-File Undo-Transaction Unregister-Event Unregister-PSSessionConfiguration
158
Update-FormatData Update-Help Update-List Update-TypeData Use-Transaction
159
V:
160
W:
161
Wait-Event Wait-Job Wait-Process Where-Object Write-Debug Write-Error Write-EventLog
162
Write-Host Write-Output Write-Progress Write-Verbose Write-Warning
163
X:
164
Y:
165
Z:
MIME types defined: application/x-powershell
.