Final Code Snippets Flashcards

0
Q

get-service | convertto-html > services.html

A

Lists all services and makes HTML file

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

get-childitem . -include *.txt -recurse | foreach-object {cp $_textfile}

A

gets childitem from text files

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

$a=get-process | where-object {$_.cpu -gt 5}

A

Lists all processes and converts to HTML file

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

$s=”now is the time”

A

Creates variable s that equals now is the time

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

$myproc=get-process Firefox

A

Gets process Firefox for the variable myproc

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