function Create-FSOIfNotExists{param([ValidateNotNullOrEmpty()]$path,[ValidateSet(Directory,File)]$itemtype)
if(-not(Test-Path -Path $path))
{
New-Item -Path $path -ItemType $itemtype |
Out-Null;
}
}
All sorts of Verbose output could (probably should) be added to this to make it chattier, but, I just needed a quick utility function and this does the trick.