1
0
Fork 0
mirror of https://github.com/Zedfrigg/ironbar.git synced 2025-09-15 19:26:58 +02:00

docs(sysinfo): add info on querying values

Resolves #1090
This commit is contained in:
Jake Stanger 2025-07-15 22:45:49 +01:00
commit 34da5edfe0
No known key found for this signature in database
GPG key ID: C51FC8F9CB0BEA61

View file

@ -194,12 +194,12 @@ The list of available functions is shown below:
It is also possible to get only a single value from the set by specifying a name instead of a function. It is also possible to get only a single value from the set by specifying a name instead of a function.
| Token category | Valid name | | Token category | Valid name |
|----------------|-------------------------------------------------------------------------| |----------------|------------------------------------------|
| CPU | A CPU thread, eg `cpu0`, `cpu1`, ... | | CPU | A CPU thread, eg `cpu0`, `cpu1`, ... |
| Temperature | A sensor name, eg `CPUTIN`. These line up with the output of `sensors`. | | Temperature | A sensor name, eg `CPUTIN`. |
| Disk | A disk mountpoint, eg `/`, `/home`, ... | | Disk | A disk mountpoint, eg `/`, `/home`, ... |
| Network | An adapter name, eg `eth0` or `enp30s0`. | | Network | An adapter name, eg `eth0` or `enp30s0`. |
To specify a name or function, use a `@`. For example, to show disk percent for `/home`: To specify a name or function, use a `@`. For example, to show disk percent for `/home`:
@ -214,6 +214,22 @@ To show total CPU utilization where each core represents 100% (like `htop` etc):
"{cpu_percent@sum}%" "{cpu_percent@sum}%"
``` ```
> [!TIP]
> Available values can be queried over IPC using the CLI.
> This can be particularly useful for sensors, which tend not to have obvious names.
>
> ```shell
> ironbar var list sysinfo.temp_c
> ```
>
> Some usual cases to look out for:
>
> - `k10temp` is an AMD CPU internal sensor
> - Motherboard chipsets tend to prefix their sensors accordingly. For example, `CPUTIN`, `nct6687 CPU`, `asusec AMD`.
> - `amdgpu` is as it suggests.
>
> Sensor names are pulled from `hwmon` and should vaguely line up with the output of `sensors`
#### Prefixes and units #### Prefixes and units
For tokens which return an appropriate unit, you can specify the SI prefix (or unit in some special cases). For tokens which return an appropriate unit, you can specify the SI prefix (or unit in some special cases).