Commit graph

1496 commits

Author SHA1 Message Date
Yutaro Ohno
963b9d47ee modules/dwl: handle the appid status
dwl added an "appid" field as output status [1]. We currently don't
handle this field, and thus output warnings that say "UNKNOWN action".

Handle the "appid" field correctly and expose a value of this field to
users. Also, suppress the warnings.

Link: 7f9a212476 [1]
2023-03-26 16:08:55 +09:00
Armin Fisslthaler
daeb59e021 i3: add native sorting to changelog 2023-03-24 19:00:21 +01:00
Armin Fisslthaler
3ec6fa1bc7 i3: update man page to include native sorting 2023-03-24 18:59:49 +01:00
Armin Fisslthaler
f21db9caca i3: add "native" sway/i3 sort mode
This adds a sort mode for workspaces which corresponds to the default
behavior in sway/i3.
2023-03-24 17:48:26 +01:00
Oleg Hahm
8ccd79ad08 modules/network: do not use IPv6 link-local
Probably you don't want to see your IPv6 link-local address but rather a
global one.
2023-03-08 18:41:20 +01:00
Daniel Eklöf
d1776714ed
Merge branch 'pipewire-roundf'
Closes #262
2023-01-21 15:50:22 +01:00
Leonardo Hernández Hernández
5da51210de
module/dwl: allow specify the name of tags 2023-01-16 19:53:21 -06:00
Ogromny
7773a17d57 CHANGELOG.md: add issue #262 2023-01-16 10:29:16 +01:00
Ogromny
bdbcc0100a modules/pipewire: change type of volume from uint8 to uint16 2023-01-16 10:29:16 +01:00
Ogromny
10fde4dd0a modules/pipewire: use roundf instead of ceilf for more accuracy 2023-01-16 10:29:16 +01:00
Daniel Eklöf
134ae847dc
module/river: add support for ‘layout’ events 2023-01-12 18:15:16 +01:00
Daniel Eklöf
f75168796a
module/pipewire: handle failures when trying to connect to pipewire
* Replace asserts() with error logs
* Handle not being connected in content()
* Return from run() with an error
2023-01-02 14:08:21 +01:00
Daniel Eklöf
d09d88b60b
ci: drop gitlab CI
We’re no longer mirroring to gitlab.
2023-01-02 13:52:39 +01:00
Daniel Eklöf
0f3894bf63
tag: handle width formatter on ints when no other formatting options are used
For example: in {cpu:3}, the ‘3’ were ignored, assuming ‘cpu’ was an
int tag.
2023-01-02 12:19:17 +01:00
Daniel Eklöf
38a1d0b57c
doc: tags: add a couple of formatting examples 2023-01-02 11:51:43 +01:00
Daniel Eklöf
11bef7dd08
doc: tags: re-arrange columns in ‘formatting’ table
Put the ‘description’ column last. Since the last column is expanded
to fill the screen, and the tags’ descriptions can be fairly long, it
makes sense to put the description column last.
2023-01-02 11:39:19 +01:00
Leonardo Gibrowski Faé
146759bd96
implement field width tag format option
This implements the possibility of specifying padding for numeric tags.
Both space and zero padding is supported.
2023-01-01 16:22:44 -03:00
Daniel Eklöf
73ccafdade
module/i3: fix regression in handling of persistent workspaces
bbd2394601 added support for ‘rename’
and ‘move’ events. In order to do that, it changed how workspace
events are matched against our internal workspace list: from string
comparing the workspace name, to checking i3/sway’s workspace ID
parameter.

This introduced a regression in our handling of persistent
workspaces. A persistent workspace is one that isn’t removed from the
bar when it’s deleted (empty, and switched away from) by i3/sway.

This concept doesn’t exist in i3/sway, but is something we’ve
added. Put simple, the way we do this is be keeping the workspace in
our list, even when i3/sway tells us it has been deleted.

However, at this point the workspace doesn’t have an ID anymore. And
the same is true at startup; when we initialize the persistent
workspaces, we only have their names. Not their IDs (since the
workspaces don’t actually exist yet).

To this the regression, we need to:

a) fallback to looking up workspaces by name. That is, if we fail to
  find one with a matching ID, try again using the workspace name. For
  _this_ to match, we also required the matched workspace to be a
  persistent workspace, with an ID < 0 (which essentially means the
  workspace doesn’t exist yet).

b) reset the ID to -1 when a persistent workspace is "deleted".

Closes #253
2022-12-28 15:21:46 +01:00
Leonardo Hernández Hernández
02d281df58
module/dwl: correctly handle the title
Uupdate the title when process a new batch of info instead of call
strtok_r and looping until `string` is NULL.

This fixes an issue where only the last part of the title was kept.
2022-12-28 15:19:11 +01:00
Daniel Eklöf
e4edbd26c6
modules: change min poll interval from 500ms to 250ms 2022-12-27 13:20:31 +01:00
Daniel Eklöf
310c07b03d
module/battery: using a static buffer in readline_from_fd() isn’t thread safe 2022-12-27 13:17:06 +01:00
Daniel Eklöf
2283647fc7
Merge branch 'poll-interval-milliseconds'
Closes #244
2022-12-23 11:06:14 +01:00
Daniel Eklöf
d26d3953f1
changelog: batter/network/script: poll-interval: seconds -> milliseconds 2022-12-22 12:09:43 +01:00
Daniel Eklöf
c4f820e486
module/script: poll-interval: convert value from ‘seconds’ to ‘milliseconds’ 2022-12-22 12:06:25 +01:00
Daniel Eklöf
500b051fe4
module/network: poll-interval: convert value from ‘seconds’ to ‘milliseconds’ 2022-12-22 12:06:15 +01:00
Daniel Eklöf
8fbbce10a5
module/battery: poll-interval: convert value from ‘seconds’ to ‘milliseconds’ 2022-12-22 11:59:02 +01:00
Daniel Eklöf
ac8e45c331
module/mem: cleanup poll-interval
* man page: spell out ‘milliseconds’
* use a ‘static const’ variable for min_poll_interval, instead of a
  macro
2022-12-22 11:47:44 +01:00
Daniel Eklöf
a18296a179
module/disk-io: cleanup poll-interval
* man page: spell out ‘milliseconds’
* use a ‘static const’ variable for min_poll_interval, instead of a
  macro
2022-12-22 11:47:44 +01:00
Daniel Eklöf
1f25978eb4
module/cpu: cleanup poll-interval
* man page: spell out ‘milliseconds’
* use a ‘static const’ variable for min_poll_interval, instead of a
  macro
2022-12-22 11:46:00 +01:00
Stanislav Ochotnický
c0e0702a6c Update Font Awesome 5 to 6
This makes it less likely that new users will get confused and
accidentally use fallback fonts.
2022-12-21 17:06:25 +01:00
Horus
23d47656e4 Merge pr 'doc: Reinclude yambar-modules man page' (#245) into master
Reviewed-on: https://codeberg.org/dnkl/yambar/pulls/245
2022-12-19 18:01:03 +00:00
Ben Brown
4318765030 doc: Reinclude yambar-modules man page 2022-12-19 17:56:25 +00:00
Daniel Eklöf
cb8acf261a
module/mem: rename ‘interval’ to ‘poll-interval’ 2022-12-18 16:51:41 +01:00
Daniel Eklöf
63c9c90a61
module/disk-io: rename ‘interval’ to ‘poll-interval’ 2022-12-18 10:38:56 +01:00
Daniel Eklöf
252a7a1580
doc: cpu: ‘interval’ has been renamed to ‘poll-interval’
Closes #241
2022-12-18 10:37:22 +01:00
Daniel Eklöf
710cede371
module/pipewire: disable debug logging 2022-12-17 18:26:31 +01:00
Daniel Eklöf
ede6a541e1
modules: meson: add missing ‘m’ (math) dependency
The following modules used functions from the ‘m’ (math)
library (e.g. round()), but didn’t explicitly link against it. This
caused build failures when no other plugin that _did_ link against ‘m’
was enabled.

* cpu
* mem
* pulse
* pipewire
* foreign-toplevel

Closes #239
2022-12-17 18:26:25 +01:00
Daniel Eklöf
a9ce81b376
changelog: add new ‘unreleased’ section 2022-12-17 10:32:36 +01:00
Daniel Eklöf
a599e7264f
Merge branch 'releases/1.9' 2022-12-17 10:32:14 +01:00
Daniel Eklöf
1353d635c2
meson/pkgbuild: bump version to 1.9.0 2022-12-17 10:29:11 +01:00
Daniel Eklöf
ef7b4ce9b3
changelog: prepare for 1.9.0 2022-12-17 10:28:41 +01:00
Daniel Eklöf
06bf127332
doc: expand last column to fill screen in all tables 2022-12-14 12:18:47 +01:00
Daniel Eklöf
b195bc4dcb
module/cpu: make ‘content’ particle a template
Before this patch, the cpu module instantiated a single particle (the
‘content’ particle), with one tag ("cpu") representing the total CPU
usage, and then one tag (cpuN) for each core.

This makes it cumbersome to configure, since you need to explicitly
reference each cpuN tag to get per-core usage.

This patch rewrites this, so that ‘content’ is now a template. It’s
instantiated once to represent the total CPU usage, and then once for
each core.

Each instance has a "cpu" tag, representing the CPU usage of that
core (or total usage). It also has an "id" tag. The ID is 0..n for
actual cores, and -1 for total usage.

This means you can do something like this in your config:

- cpu:
    content:
      map:
        conditions:
          id < 0: {string: {text: "Total: {cpu}%"}}
          id >= 0: {string: {text: "Core #{id}: {cpu}%"}}

Closes #207
2022-12-14 12:06:00 +01:00
Daniel Eklöf
2e0e1a402f
bar: also log module name when logging a failed module 2022-12-14 12:05:34 +01:00
Daniel Eklöf
3ca274759a
module: const:ify ‘module’ argument to module->description() 2022-12-14 12:05:17 +01:00
Daniel Eklöf
6794193791
Merge branch 'plugin-compile-time-optional' 2022-12-14 11:03:16 +01:00
Daniel Eklöf
95b1f5f261
modules: meson: regression: it’s ‘libudev’, not ‘udev’ 2022-12-14 11:01:05 +01:00
Daniel Eklöf
b22614ecc3
ci (woodpecker): add pipewire-dev to x86 builds
Before this, it was only added in the x64 builds
2022-12-14 10:54:26 +01:00
Daniel Eklöf
c4cc1b7a36
changelog: all modules are now compile-time optional 2022-12-14 10:30:20 +01:00
Daniel Eklöf
a53e48a2c1
doc: meson: only install man pages for modules we actually build 2022-12-14 10:29:08 +01:00