Monthly Archives: January 2019

Create a temporary folder in powershell

I needed to create a temporary folder. I modified the code found here One issue in the original code was the chance (albeit extremely slight) of having a name collision with an existing folder. The script below checks and tries 5 times before failing. It isn’t neat, and is somewhat of a brute force method of getting around the issue, but it gets the job done. You can see the modified code here