Summary
In this chapter, we examined the concept of code smells, which are related to best practices and antipatterns. We looked at several code smells that are found in most programming languages and then looked in-depth at code smells that are specific to PowerShell scripts due to the unique nature of PowerShell. Finally, we examined the state of static script analysis in PowerShell, reviewing the functionality of ScriptCop and the Script Analyzer add-on.