IT之家 4 月 25 日消息,與許多操作系統(tǒng)一樣,微軟也在其 Windows 11、Windows 10 和其他產(chǎn)品中提供了一堆默認應用。Oofhours 的一份新報告就揭開了 Windows 11 中的默認應用有多大。
如下圖所示,使用 PowerShell 提供的查詢功能,我們能夠計算出 Windows 11 默認應用的大小。這些應用已按大?。ㄒ宰止?jié)為單位)降序排序,可以看到 Microsoft Teams 是最大的應用,占用了大約 91MB 的空間。

然而,該查詢只是指向了 XML 文件位置,而部分應用有另一個文件夾,需要額外計算大小。比如 Microsoft Store Purchase 顯示大小為 11KB,但實際大小為 37MB。

對列出的每一個應用進行檢查后發(fā)現(xiàn),Windows 11 的默認預裝應用大小約為 1.6GB,IT之家小伙伴覺得多不多?

以下是在 PowerShell 中查看所有 Windows 應用大小的腳本,包括默認應用和從 Microsoft Store 下載的應用(需要先取消隱藏 WindowsApps 文件夾):
Get-AppxProvisionedPackage -online | % {
# Get the main package location using the manifest
$loc = Split-Path ( [Environment]::ExpandEnvironmentVariables($_.InstallLocation) ) -Parent
If ((Split-Path $loc -Leaf) -ieq 'AppxMetadata') {
$loc = Split-Path $loc -Parent
}
# Get a pattern for finding related folders
$matching = Join-Path -Path (Split-Path $loc -Parent) -ChildPath "$($_.DisplayName)*"
$size = (Get-ChildItem $matching -Recurse -ErrorAction Ignore | Measure-Object -Property Length -Sum).Sum
# Add the results to the output
$_ | Add-Member -NotePropertyName Size -NotePropertyValue $size
$_ | Add-Member -NotePropertyName InstallFolder -NotePropertyValue $loc
$_
} | Select DisplayName, PackageName, Version, InstallFolder, Size廣告聲明:文內(nèi)含有的對外跳轉(zhuǎn)鏈接(包括不限于超鏈接、二維碼、口令等形式),用于傳遞更多信息,節(jié)省甄選時間,結(jié)果僅供參考,IT之家所有文章均包含本聲明。