PowerShell Flashcards

(38 cards)

1
Q

*

A

Wildcard that sets up a match with any number of characters

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

?

A

Wildcard that sets up a match with a single character

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

$env:path

A

Shows the default path PowerShell will use to search for the script you entered.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Get-Process

A

Shows all the currently running processes

“-Processname” allows you to specific a specific parameter

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Get-ChildItem

A

Retrives the contents of the current folder, or one you specify the path to.

Aliases: dir, ls

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

get-service winrm

A

Checks if WinRM is running

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

start-service winrm

A

Starts WinRM

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

&$pshome\configure-wsman.ps1

A

Configures the WS-Management protocol to work with PowerShell

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Get-Host

A

The cmdlet for programmatically configuring the Windows PowerShell console.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Clear-Host

A

Refreshes the console window and forces the immediate application of the Get-Host configuration options you just set.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Get-History

A

Accesses the history buffer commands and inserts them into the Windows PowerShell pipeline allowing you to programmatically access and manipulate them.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Invoke-History

A

Takes as an argument a number representing the position of a command in the history buffer.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Get-PSProvider

A

Shows a listing of all providers supported by Windows PowerShell.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Get-PSDrive

A

Displays a listing of available drives and the provider with which they are associated.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Set-Location

A

Changes the current drive.

Aliases: sl, cd, pwd, chdir

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Read-Host

A

Pauses the script until the users presses enter

17
Q

Up arrow

A

Moves back one position in the command line history buffer

18
Q

Down arrow

A

Moves forward one position in the command line history buffer

19
Q

Page up

A

Moves to the first command stored in the command line history buffer

20
Q

Page down

A

Moves to the last command stored in the command line history buffer

21
Q

Home

A

Jumps the cursor to the beginning of the command line

22
Q

End

A

Jumps the cursor to the end of the command line

23
Q

Control+Left

A

Moves the cursor to the left a word at a time

24
Q

Control+Right

A

Moves the cursor to the right a word at a time

25
Get-Member
Gets the properties, methods, typeinfo, and property sets of the objects given to it.
26
Select-Object
Selects objects based on parameters set in the cmdlet command string.
27
About-PSJob
Provides a high-level overview of how to work with background jobs.
28
Start-PSJob
Creates and executes a new local or remote background job.
29
Receive-PSJob
Retrieves output generated by a background job. Once retrieved, the output is removed and no longer retrievable, unless you use the -keep argument.
30
Wait-PSJob
Instructs PowerShell to wait for a background job to complete.
31
Stop-PSJob
Halts the execution of a background job. Can use either its session ID or its state,
32
Get-PSJob
Retrieves information about the status of a background job using the session ID number.
33
Remove-PSJob
Deletes a background job object (including all of its output).
34
New-Runspace
Sets up a persistent runspace in which to execute remote jobs.
35
Get-Service
Gets a list of services.
36
Start-Sleep
Puts your PowerShell script to sleep for a specified period of time (in seconds).
37
Where-Object
Removes objects failing to meet a specified criteria. A filter.
38
$_
A special variable created and maintained by Windows PowerShell. It is automatically assigned the name of the current object in the pipeline and can reference each object in a collection.