Private/New-TemporaryDirectory.ps1
# SPDX-FileCopyrightText: © 2022 David Haymond <david@davidhaymond.dev> # # SPDX-License-Identifier: GPL-3.0-or-later function New-TemporaryDirectory { [CmdletBinding(SupportsShouldProcess = $true)] param() $name = [System.IO.Path]::GetRandomFileName() $path = [System.IO.Path]::GetTempPath() New-Item -Path $path -Name $name -ItemType Directory } |