en-us/A_Quick_Intro_To_ScriptCop.walkthru.help.txt

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# ScriptCop is a PowerShell module that helps ensure your scripts are following the rules.
# It's what is called a 'Static Analysis' tool, meaning that it doesn't run your scripts, it just looks at them.
# ScriptCop has an ever-expanding list of rules that check for a variety of different problems with Powershell commands.
 
# You can use ScriptCop a few different ways:
 
# By declaring one or more commands in a scriptblock, like:
Test-Command -ScriptBlock {
    function IsThisGoodPowerShell{
    }
}
 
# By piping in a list of commands, like:
Get-Command -Verb Get -Module *PowerShell* | Test-Command
 
# By piping in a module, like:
Get-Module -Name ScriptCop | Test-Command