Set-PSDebug -Strict

Topics: Developer Forum
Feb 10, 2007 at 8:05 AM
I suggest that we all put this line as the first executable line of script in our profile.ps1 files. I don't think I want to put this in the shipping profile.ps1 file unless we somehow turned off except for PSCX development.
Feb 10, 2007 at 10:41 PM
Couldn't we just put Set-PSDebug -Strict at the start of our profile, and Set-PSDebug -Off at the end?
Feb 10, 2007 at 10:58 PM
I dunno. Is it enough for PowerShell to parse our dot-source scripts to find uninitialize variable references or do you have to actually execute that code. I thought you had to execute the code (could be wrong though) in which case I don't think your suggestion would work.
Feb 10, 2007 at 11:01 PM
ah, you're right.