WinGet
非官方测试版翻译
本页面由 PageTurner AI 翻译(测试版)。未经项目官方认可。 发现错误? 报告问题 →
功能
显示可用的 WinGet 包更新数量。此片段仅在存在可用更新时显示。
信息
此片段仅在 Windows 上可用。
示例配置
- json
- yaml
- toml
{
"type": "winget",
"style": "powerline",
"powerline_symbol": "",
"foreground": "#ffffff",
"background": "#0077c2",
"template": " {{ .UpdateCount }} ",
"cache": {
"duration": "24h",
"strategy": "device"
}
}
type: winget
style: powerline
powerline_symbol:
foreground: "#ffffff"
background: "#0077c2"
template: " {{ .UpdateCount }} "
cache:
duration: 24h
strategy: device
type = "winget"
style = "powerline"
powerline_symbol = ""
foreground = "#ffffff"
background = "#0077c2"
template = " {{ .UpdateCount }} "
[cache]
duration = "24h"
strategy = "device"
模板 (信息)
默认模板
\uf409 {{ .UpdateCount }}
属性
| Name | Type | Description |
|---|---|---|
.UpdateCount | int | the number of packages with available updates |
.Updates | []WinGetPackage | array of packages with available updates |
WinGet 包
| Name | Type | Description |
|---|---|---|
.Name | string | the package name |
.ID | string | the package ID |
.Current | string | the currently installed version |
.Available | string | the available version for update |