我在PowerShell中那種跑出來的選項現在......下載Windows中大型文件的命令提示符/ PowerShell的
嘗試1
使用IWR。它的工作原理,顯示了進步,但它的10X速度較慢,不沖水,直到當文件在內存中:(。
powershell -command "& { iwr https://github.com/mitchellspryn/AirsimHighPolySuv/releases/download/V1.0.0/SUV.zip -OutFile SUV.zip }"
嘗試2
使用的.Net Web客戶端在PowerShell中,它的工作原理,但目前尚無你不能按Ctrl + C :(終止進程。最後一個問題是一個很大的挫折。
powershell -command "& { (New-Object System.Net.WebClient).DownloadFile('https://github.com/mitchellspryn/AirsimHighPolySuv/releases/download/V1.0.0/SUV.zip', 'SUV.zip') }"
嘗試3
在Powershell中使用BITS傳輸。它的工作原理,顯示進步和近乎完美...直到你發現它mysteriously doesn't work on GitHub(錯誤與403禁止)!
powershell -command "& { Start-BitsTransfer -Source https://github.com/mitchellspryn/AirsimHighPolySuv/releases/download/V1.0.0/SUV.zip -Destination SUV.zip }"
爲什麼單獨運行'powershell.exe'('powershell.exe -command ...')?只需從PowerShell命令行直接運行所需的命令即可。 –
我從另一個構建腳本中使用它,並將整個腳本轉換爲PS並不是我們現在的目標。 – ShitalShah