คำสั่งสำหรับติดตั้ง Unity 2021 โดยไม่มีหน้าต่างถามตอบ ถอนการติดตั้ง และตรวจจับจากเครื่องมือกระจายซอฟต์แวร์ เราแสดงคำสั่งเฉพาะเมื่อแน่ใจเท่านั้น คือมาจากแมนิเฟสต์หรือค่าเริ่มต้นที่มีเอกสารของเทคโนโลยีตัวติดตั้งนั้น
คู่มือที่เกี่ยวข้อง: พารามิเตอร์ติดตั้งแบบเงียบ: MSI, NSIS, Inno Setup · ถอนการติดตั้งโปรแกรมผ่านรีจิสทรีหรือ PowerShell
ใช้ winget
PowerShell
winget install --id Unity.Unity.2021 -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id Unity.Unity.2021 -e --silentwinget uninstall --id Unity.Unity.2021 -e --silentแยกตามตัวติดตั้ง
64 บิต · EXE (NSIS) · ผู้ใช้ทุกคน
ติดตั้งแบบเงียบ
UnitySetup64-2021.3.45f2.exe /Sกำหนดโฟลเดอร์เอง
UnitySetup64-2021.3.45f2.exe /S /D=C:\Apps\unity-2021- คีย์รีจิสทรีสำหรับถอนการติดตั้ง
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Unity 2021.3.45f2
PowerShell: ดาวน์โหลด ตรวจสอบ ติดตั้ง
ดาวน์โหลดไฟล์ทางการ ตรวจสอบค่า SHA256 แล้วติดตั้งแบบเงียบ
install-unity-2021.ps1
$url = 'https://download.unity3d.com/download_unity/88f88f591b2e/Windows64EditorInstaller/UnitySetup64-2021.3.45f2.exe'
$sha256 = 'AC7B45ED97D59F173D70A993362C84909C8C4B63280BD4CC30F9A5989ABF2596'
$file = Join-Path $env:TEMP 'UnitySetup64-2021.3.45f2.exe'
Invoke-WebRequest -Uri $url -OutFile $file -UseBasicParsing
if ((Get-FileHash $file -Algorithm SHA256).Hash -ne $sha256) { throw 'SHA256 mismatch' }
Start-Process -FilePath $file -ArgumentList '/S' -Wait