feat: Usage & Spend tab, external hooks, Cursor cost labels (0.44/0.45 deferred)#229
Merged
Conversation
Port deferred 0.44/0.45 UI pieces: - Settings Usage & Spend tab with 7d/30d CostScanner aggregates - External hooks runner (hooks.json) with env whitelist + rate limit - hooks_enabled setting + Advanced tab help - Cursor CostSnapshot period labels for plan/on-demand spend
|
This repository allows each user to open at most 4 pull requests per 7 days. Closing this automatically. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Ports deferred upstream 0.44/0.45 UI pieces to Win-CodexBar:
1. Usage & Spend settings tab (upstream 0.44 steipete#2116)
usageSpendsettings tab with provider | 7d | 30d | currency tableget_usage_spend_summaryusingCostScannerfor Codex/Claude local logs2. External hooks (upstream steipete#2001) — minimal but real
rust/src/core/hooks.rs: HookEvent, HookRule, HooksConfig, HookRunner, HookRateLimiter%APPDATA%\CodexBar\hooks.json(next to settings)CODEXBAR_*hooks_enabled+ path help text3. Cursor token-cost deepen (best-effort)
On-demand (billing cycle)andPlan (since …)from existing usage-summary fields only (no new network endpoints)Tests
Note:
core::provider::tests::test_provider_id_allfails pre-existing (63 vs 59 count from earlier provider ports); unrelated to this change.Example hooks.json
{ enabled: true, events: [ { enabled: true, event: quota_low, threshold: 0.7, executable: C:\\\\path\\\\to\\\\notify.exe, arguments: [], timeoutSecs: 10 } ] }Need help on this PR? Tag
/codesmithwith what you need. Autofix is disabled.