Repository navigation
feat(fetcher): add system_battery realtime fetcher - #123
Conversation
Reads laptop battery state via starship-battery and emits Ratio (pairs with gauge_battery / gauge_circle / gauge_segment / gauge_line), Text (summary / percent / status / time_remaining via the kind option), or Entries (charge / state / time_left / cycles / health). Hosts without a battery (desktops, servers) render as a "full AC" stand-in so the widget slot stays visible instead of silently disappearing. Ticks the system_battery box on #62. Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 57 minutes and 16 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #123 +/- ##
==========================================
- Coverage 78.41% 78.25% -0.16%
==========================================
Files 95 95
Lines 17304 17542 +238
==========================================
+ Hits 13569 13728 +159
- Misses 3735 3814 +79
🚀 New features to boost your workflow:
|
Summary
system_batteryrealtime fetcher backed bystarship-battery. Pairs with the existinggauge_batteryrenderer family.Ratio(charge 0..=1, default),Text(formatted viakindoption),Entries(charge / state / time_left / cycles / health)."AC", singlepower = ACentry) so the widget doesn't silently disappear.Ticks the
system_batterybox on #62.ratio,text,entriesOptions
kindTextshape. Ignored byRatio/Entries.indexCompatible renderers
ratioanimated_boot,animated_postfx,animated_scanlines,animated_splitflap,animated_wave,gauge_battery,gauge_circle,gauge_line,gauge_segmenttextanimated_boot,animated_figlet_morph,animated_postfx,animated_scanlines,animated_splitflap,animated_typewriter,animated_wave,text_ascii,text_plainentriesanimated_boot,animated_postfx,animated_scanlines,animated_splitflap,animated_wave,grid_tableTest plan
cargo fmt --all -- --checkcargo clippy --all-targets -- -D warningscargo test(28 system tests pass — kind branches, shape branches, no-battery fallback, options error)cargo run --bin splashboardwith all four gauge renderers + three Textkindvariants +grid_tableFollow-up
While testing the smoke fixture I noticed unknown fetcher names silently drop widgets from the layout instead of rendering an in-band error like unknown renderers do — filed as #121.
🤖 Generated with Claude Code