Commit graph

11 commits

Author SHA1 Message Date
7bba60e323 Impl 0.1.5 of swaybar_info
Implemented `--netdev_width=<width>` which sets the minimum width of the netdev
byte/KiB/MiB text displays.

Implemented `--netgraph_max_bytes=<bytes>` which displays a graph in text using
Unicode "Block Elements" symbols. The `<bytes>` argument determines the maximum
amount of bytes that will determine which block-character is printed on the
interval. The graph is always 10 characters wide, and the right side is the
most-recent side. Note that this always checks against the maximum of either
download or upload rates. For example, if `<bytes>` is set to 1024, and 128
bytes were downloaded and 512 bytes were uploaded in an interval, the "Lower
Half Block" Unicode symbol will be emitted (exactly half).

SwaybarObject was changed to use an `Option<String>` instead of an `Option<u16>`
for `min_width`.
2022-10-18 21:04:28 +09:00
a9b8e67d58 Bump version to 0.1.1, fix warnings 2022-08-11 11:51:12 +09:00
a1956b852a Impl way to set the time format 2022-08-11 11:47:49 +09:00
90dee55e7a Remove outdated TODO comments 2022-07-10 18:02:00 +09:00
f9961a149d Refactor net error handling 2022-07-10 17:58:10 +09:00
8b0c892f05 Refactor SwaybarArray::get_by_name* to use a map
Also some other minor refactorings.
2022-07-10 15:11:01 +09:00
eb09c43375 Refactor SwaybarArray to be modified not recreated 2022-07-10 14:57:43 +09:00
313bb30794 Impl output loop 2022-07-09 18:18:12 +09:00
0df98bc2a9 Impl parsing /proc/meminfo, create object with str 2022-07-09 16:57:49 +09:00
ff3d53c64d Add swaybar protocol header 2022-07-09 16:33:59 +09:00
237d95bb52 Impl struct for swaybar objects and output test 2022-07-09 16:25:15 +09:00