設(shè)置
  • 日夜間
    隨系統(tǒng)
    淺色
    深色
  • 主題色

報告:微軟 Win11 默認預(yù)裝應(yīng)用約占 1.6GB 磁盤空間

2022/4/25 7:32:41 來源:IT之家 作者:汪淼 責編:汪淼

IT之家 4 月 25 日消息,與許多操作系統(tǒng)一樣,微軟也在其 Windows 11、Windows 10 和其他產(chǎn)品中提供了一堆默認應(yīng)用。Oofhours 的一份新報告就揭開了 Windows 11 中的默認應(yīng)用有多大。

如下圖所示,使用 PowerShell 提供的查詢功能,我們能夠計算出 Windows 11 默認應(yīng)用的大小。這些應(yīng)用已按大小(以字節(jié)為單位)降序排序,可以看到 Microsoft Teams 是最大的應(yīng)用,占用了大約 91MB 的空間。

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

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

以下是在 PowerShell 中查看所有 Windows 應(yīng)用大小的腳本,包括默認應(yīng)用和從 Microsoft Store 下載的應(yīng)用(需要先取消隱藏 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之家所有文章均包含本聲明。

相關(guān)文章

關(guān)鍵詞:Win11

軟媒旗下網(wǎng)站: IT之家 最會買 - 返利返現(xiàn)優(yōu)惠券 iPhone之家 Win7之家 Win10之家 Win11之家

軟媒旗下軟件: 軟媒手機APP應(yīng)用 魔方 最會買 要知