Java 8 ကို မေးခွန်းမမေးဘဲ ထည့်သွင်းရန်၊ ပြန်ဖယ်ရှားရန်နှင့် deployment ကိရိယာများမှ ထောက်လှမ်းရန် command များ ဖြစ်ပါသည်။ command တစ်ခုကို သေချာမှသာ ပြပါသည် — manifest မှ သို့မဟုတ် installer နည်းပညာ၏ မှတ်တမ်းတင်ထားသော မူလတန်ဖိုးမှ ဖြစ်ပါသည်။
ဆက်စပ် လမ်းညွှန်: အသံတိတ်ထည့်သွင်းခြင်း switch များ - MSI၊ NSIS၊ Inno Setup · Registry သို့မဟုတ် PowerShell ဖြင့် ပရိုဂရမ် ဖယ်ရှားနည်း
winget ဖြင့်
winget install --id Oracle.JavaRuntimeEnvironment -e --silent --accept-package-agreements --accept-source-agreementswinget upgrade --id Oracle.JavaRuntimeEnvironment -e --silentwinget uninstall --id Oracle.JavaRuntimeEnvironment -e --silentInstaller အလိုက်
64-bit · EXE · အသုံးပြုသူအားလုံး
AutoDL /s REBOOT=0msiexec /x {73224AE4-039E-4CA4-87B4-2F64180511F0} /qn /norestart- MSI product code
- {73224AE4-039E-4CA4-87B4-2F64180511F0}
- Uninstall registry key
- HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{73224AE4-039E-4CA4-87B4-2F64180511F0}
- UpgradeCode
- {57BDA5C6-443C-4D65-B233-282396418000}
32-bit · EXE · အသုံးပြုသူအားလုံး
AutoDL /s REBOOT=0msiexec /x {73224AE4-039E-4CA4-87B4-2F32180511F0} /qn /norestart- MSI product code
- {73224AE4-039E-4CA4-87B4-2F32180511F0}
- Uninstall registry key
- HKLM\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\{73224AE4-039E-4CA4-87B4-2F32180511F0}
- UpgradeCode
- {57BDA5C6-443C-4D65-B233-282393218000}
PowerShell - ဒေါင်းလုဒ်၊ စစ်ဆေး၊ ထည့်သွင်း
တရားဝင်ဖိုင်ကို ဒေါင်းလုဒ်လုပ်ပြီး SHA256 ကို စစ်ဆေးကာ အသံတိတ် ထည့်သွင်းပါသည်။
$url = 'https://javadl.oracle.com/webapps/download/AutoDL?BundleId=254080_ee9438f370f14316bf0d13e23c26582b'
$sha256 = '5449042A34892DEA95788C6A86E0FEEE5B32EBF500318622733C2D492DA0D391'
$file = Join-Path $env:TEMP 'AutoDL'
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 REBOOT=0' -Wait $url = 'https://javadl.oracle.com/webapps/download/AutoDL?BundleId=254079_ee9438f370f14316bf0d13e23c26582b'
$sha256 = 'F3FE6C1C4F8C960BB23AA2BA2EB39944737F3E66D19D18F28C30A6FBC2C21896'
$file = Join-Path $env:TEMP 'AutoDL'
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 REBOOT=0' -Wait