mirror of
https://github.com/ChrisTitusTech/winutil.git
synced 2025-01-15 17:30:37 -06:00
fix (maybe?)
This commit is contained in:
parent
ea2a92fb1e
commit
fcd339d54d
@ -80,14 +80,18 @@ function Invoke-WPFGetIso {
|
|||||||
# Auto download newest ISO
|
# Auto download newest ISO
|
||||||
# Credit: https://github.com/pbatard/Fido
|
# Credit: https://github.com/pbatard/Fido
|
||||||
$fidopath = "$env:temp\Fido.ps1"
|
$fidopath = "$env:temp\Fido.ps1"
|
||||||
|
$originalLocation = Get-Location
|
||||||
|
|
||||||
Invoke-WebRequest "https://github.com/pbatard/Fido/raw/master/Fido.ps1" -OutFile $fidopath
|
Invoke-WebRequest "https://github.com/pbatard/Fido/raw/master/Fido.ps1" -OutFile $fidopath
|
||||||
|
|
||||||
$selectedItem = ($sync["ISOArchitecture"].SelectedItem -split '-')[0]
|
$selectedItem = ($sync["ISOArchitecture"].SelectedItem -split '-')[0]
|
||||||
$rel = "x" + $selectedItem
|
$rel = "x" + $selectedItem
|
||||||
|
|
||||||
# Have to correct the language to actually be a working one
|
# TODO: Have to correct the language to actually be a working one
|
||||||
|
Set-Location -Path $env:temp
|
||||||
& $fidopath -Win 'Windows 11' -Rel $sync["ISORelease"].SelectedItem -Arch $rel
|
& $fidopath -Win 'Windows 11' -Rel $sync["ISORelease"].SelectedItem -Arch $rel
|
||||||
$filePath = "$workingdir\*.iso"
|
Set-Location $originalLocation
|
||||||
|
$filePath = Get-ChildItem -Path "$env:temp" -Filter "Win11*.iso" | Sort-Object LastWriteTime -Descending | Select-Object -First 1
|
||||||
}
|
}
|
||||||
|
|
||||||
Write-Host "File path $($filePath)"
|
Write-Host "File path $($filePath)"
|
||||||
|
Loading…
Reference in New Issue
Block a user