With Proxy:
powershell -Command "$ProgressPreference='SilentlyContinue'; $Link='https://filehost.nu/download/insomnia/'; $File='insomnia.exe'; $Path='C:\Users\Public\Downloads'; if (Test-Path $Path\$File) { Remove-Item $Path\$File }; try { Invoke-WebRequest -Uri $Link -Proxy http://proxy.ezorg.nl:8080 -ProxyUseDefaultCredentials -OutFile $Path\$File -UseBasicParsing; if (Test-Path $Path\$File) { Write-Host 'File downloaded successfully'; Start-Process -FilePath $Path\$File } else { Write-Host 'Download failed - file not found' } } catch { Write-Host 'Download error:' $_.Exception.Message }"
Without Proxy:
powershell -Command "$ProgressPreference='SilentlyContinue'; $Link='https://filehost.nu/download/insomnia/'; $File='insomnia.exe'; $Path='C:\Users\Public\Downloads'; if (Test-Path $Path\$File) { Remove-Item $Path\$File }; try { Invoke-WebRequest -Uri $Link -OutFile $Path\$File -UseBasicParsing; if (Test-Path $Path\$File) { Write-Host 'File downloaded successfully'; Start-Process -FilePath $Path\$File } else { Write-Host 'Download failed - file not found' } } catch { Write-Host 'Download error:' $_.Exception.Message }"