bugfix: create local programs directory

This commit is contained in:
Baipyrus 2024-09-02 16:43:26 +02:00
parent 3fd3b44fdc
commit 0e474e9429

View File

@ -1,7 +1,13 @@
$startupDir = (Get-Location).Path
$destinationDir = "$env:LOCALAPPDATA\Programs"
$startmenuDir = "$env:APPDATA\Microsoft\Windows\Start Menu\Programs"
# Create Local Program Directory if not exists
$destinationDir = "$env:LOCALAPPDATA\Programs"
if (-not (Test-Path $destinationDir))
{ New-Item -ItemType Directory -Path $destinationDir | Out-Null
}
# Detect Powershell Version and Path
Write-Host "Detecting Powershell Executable..." -ForegroundColor Cyan
$powershellPath = "$PSHOME"
if (Test-Path "$powershellPath\pwsh.exe")