| Age | Commit message (Collapse) | Author |
|
|
|
- Draw dim purple background (#180028) instead of black so disk bar slots
are visible even when the disk is idle
- First sample no longer returns early; records baseline and still draws
the bar background
- Filter out zram devices from whole-disk detection
- Add TestDiskBar_Rendering: end-to-end pixel test verifying purple bars
appear after two disk data samples
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add a new disk stats category that reads /proc/diskstats, shows read/write
throughput as colored bars (purple/darker purple like network RX/TX), with
optional utilization % overlay in extended mode. Hotkey 5 cycles: aggregate
(sum all whole-disk devices) → per-device → off. Auto-scale with decay and
optional fixed override via --diskmax / diskmax config key.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
- config: split set() (62L) into setSizeAndTuning() + setDisplayFlags()
- collector: split Run() (70L) into Run + startLocalScanner + startRemoteScanner
+ parseCollectorStream + dispatchCollectorLine; each <30L
- collector: remove unused script_embed.go (RemoteScript was dead code)
- display: move newRunState constructor before Run() per constructor-first rule
- display: replace loadPeak IIFE with a plain initLoadPeak variable
- display: split handleKey() (114L) into handleToggleKeys + handleAdjustAndSave
+ handleResizeKeys; add nil guard in handleResizeKeys for test safety
- display: split drawNetBarSmoothed() (75L) into drawNetBarSmoothed +
smoothNetUtilization + drawNetHalves; each <30L
- all: gofmt -w to fix formatting drift in display and config files
All tests pass (go test ./...).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Adds a new teal bar type showing /proc/loadavg data per host.
The 1-min average fills from the top downward; yellow and white
1px reference lines mark the 5-min and 15-min averages. A global
loadPeak tracker (floor 2.0, slow per-frame decay) keeps the scale
meaningful across hosts and after spikes. Toggle with 4 or l;
persisted to ~/.loadbarsrc as showload=1.
Bump version to 0.12.0.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
CPU display now cycles through three states with each press of 1:
0 = CPUModeAverage – aggregate bar only (default)
1 = CPUModeCores – individual core bars + aggregate
2 = CPUModeOff – all CPU bars hidden
Config file stores cpumode=N (integer); old showcores=0/1 is read for
backward compatibility. CLI flag --showcores replaced by --cpumode.
Other improvements landed in this commit:
- internal/display: add font.go (text rendering), hittest.go (bar hit
testing), tooltip.go (mouse-over tooltip), tooltip_test.go
- internal/display: mouse tracking and drawOverlay hook in display.go
- internal/display: update build tags to //go:build form
- internal/collector: embed remote script via script_embed.go /
scriptdata/loadbars-remote.sh
- internal/collector: CPULine.Total() changed to value receiver
- internal/collector: table test improvements (name field, t.Run)
- internal/constants: BytesPerSec consts promoted from var to const
- Magefile.go: fix error formatting and install path
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
When monitoring many servers, bars can become too thin to read. The new
maxbarsperrow setting (default 0 = unlimited) wraps bars into multiple
rows of equal height when the count exceeds the limit. The last row may
have fewer, wider bars filling the full window width.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Draw 1px yellow vertical lines between hosts when monitoring multiple
servers, making it easy to see where one host's bars end and the next
begins. Toggled with hotkey 's', persisted via 'w' to ~/.loadbarsrc.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add a pink 1px line drawn from the top showing mean iowait+IRQ+softIRQ
across all hosts, toggled with hotkey i and persistable to ~/.loadbarsrc.
Also add m as alias for 2 (memory toggle) and n as alias for 3 (network
toggle) for easier single-hand operation.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Draw a 1px red horizontal line spanning the full window width showing
the mean CPU usage across all monitored hosts. Toggled with 'g' hotkey
and persistable to ~/.loadbarsrc via 'w'.
Bump version to 0.10.0.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Fixes issue where integer division (winW / numBars) left unused pixels
on the right side of the window. The more cores displayed, the more
obvious the gap became.
Changes:
- Add barBounds() helper to calculate exact position and width for each bar
- Distribute remainder pixels evenly using scaled division
- Update drawing functions to use pre-calculated positions
- Update test to verify bars now fill entire window width
Increment version to 0.9.1
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
|
Sum RX/TX across all non-lo interfaces instead of picking a single one.
Remove the n hotkey (cycle interface), netint config field, and --netint
flag since they are no longer needed. Fix pre-existing bug where net bars
decayed to zero between collector updates (~19 of 20 frames had target=0,
making bars invisible even during heavy downloads).
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
Add missing f/v hotkey handlers to cycle NetLink through
mbit/10mbit/100mbit/gbit/10gbit, closing the gap between README
documentation and actual implementation. Add 13 unit tests covering
all hotkey behaviors including visual pixel assertions for toggles.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
|
drawFrame() only cleared the window on layout changes, leaving remainder
pixels (from integer division winW/numBars) with stale content from the
double-buffered back buffer. Now clears every frame per SDL2 best practice.
Adds comprehensive SDL visual test harness using software renderer with
pixel spot-checking for CPU, memory, network bars, and the remainder bug.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|