Skip to content

Commit efba3e4

Browse files
MuhammadAli511cursoragentrobinebers
authored
feat: add global shortcut to toggle panel (#132)
* feat: add global shortcut to toggle panel * updated test cases * feat(shortcuts): add tests, simplify UI, detect macOS accessibility permission * remove accessibility permission layer * fix: harden global shortcut update handling Scope shortcut unregistration to the managed global shortcut instead of unregistering all, remove unused macOS deps left from accessibility work, and fix the broken README link formatting. Co-authored-by: Cursor <cursoragent@cursor.com> * fix: improve global shortcut unregistration logic * fix: clear managed shortcut state after unregister Keep managed global shortcut state synchronized with actual registration state by clearing the in-memory value immediately after a successful unregister, so retries can re-apply the same shortcut after a failed register. Co-authored-by: Cursor <cursoragent@cursor.com> --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Robin Ebers <robin.ebers@gmail.com>
1 parent f86add4 commit efba3e4

14 files changed

Lines changed: 804 additions & 43 deletions

File tree

README.md

Lines changed: 86 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,89 @@
1-
## Build from source
1+
**Track all your AI coding subscriptions in one place.**
2+
3+
Amp, Cursor, Claude, Codex, and more coming. See your usage at a glance from your menu bar. No digging through dashboards.
4+
5+
![OpenUsage Screenshot](screenshot.png)
6+
7+
## Download
8+
9+
[**Download the latest release**](https://github.com/robinebers/openusage/releases/latest) (macOS, Apple Silicon & Intel)
10+
11+
The app auto-updates. Install once and you're set.
12+
13+
## What It Does
14+
15+
OpenUsage lives in your menu bar and shows you how much of your AI coding subscriptions you've used. Progress bars, badges, and clear labels. No mental math required.
16+
17+
- **One glance.** All your AI tools, one panel.
18+
- **Always up-to-date.** Refreshes automatically on a schedule you pick.
19+
- **Global shortcut.** Toggle the panel from anywhere with a customizable keyboard shortcut.
20+
- **Lightweight.** Opens instantly, stays out of your way.
21+
- **Plugin-based.** New providers get added without updating the whole app.
22+
23+
## Supported Providers
24+
25+
- [**Amp**](docs/providers/amp.md) / free tier, bonus, credits
26+
- [**Antigravity**](docs/providers/antigravity.md) / all models
27+
- [**Claude**](docs/providers/claude.md) / session, weekly, extra usage
28+
- [**Codex**](docs/providers/codex.md) / session, weekly, reviews, credits
29+
- [**Copilot**](docs/providers/copilot.md) / premium, chat, completions
30+
- [**Cursor**](docs/providers/cursor.md) / credits, plan usage, on-demand
31+
- [**Kimi Code**](docs/providers/kimi.md) / session, weekly
32+
- [**Windsurf**](docs/providers/windsurf.md) / prompt credits, flex credits
33+
34+
### Maybe Soon
35+
36+
- [Factory / Droid](https://github.com/robinebers/openusage/issues/16)
37+
- [Gemini](https://github.com/robinebers/openusage/issues/13)
38+
- [Vercel AI Gateway](https://github.com/robinebers/openusage/issues/18)
39+
40+
Community contributions welcome.
41+
Want a provider that's not listed? [Open an issue.](https://github.com/robinebers/openusage/issues/new)
42+
43+
## Open Source, Community Driven
44+
45+
OpenUsage is built by its users. Hundreds of people use it daily, and the project grows through community contributions: new providers, bug fixes, and ideas.
46+
47+
I maintain the project as a guide and quality gatekeeper, but this is your app as much as mine. If something is missing or broken, the best way to get it fixed is to contribute by opening an issue, or submitting a PR.
48+
49+
Plugins are currently bundled as we build our the API, but soon will be made flexible so you can build and load their own.
50+
51+
**Windows/Linux:** high-priority and on the todo, but I need testers with some time, willing to help out.
52+
53+
### How to Contribute
54+
55+
- **Add a provider.** Each one is just a plugin. See the [Plugin API](docs/plugins/api.md).
56+
- **Fix a bug.** PRs welcome. Provide before/after screenshots.
57+
- **Request a feature.** [Open an issue](https://github.com/robinebers/openusage/issues/new) and make your case.
58+
59+
Keep it simple. No feature creep, no AI-generated commit messages, test your changes.
60+
61+
## Built Entirely with AI
62+
63+
Not a single line of code in this project was read or written by hand. 100% AI-generated, AI-reviewed, AI-shipped — using [Cursor](https://cursor.com), [Claude Code](https://docs.anthropic.com/en/docs/claude-code), and [Codex CLI](https://github.com/openai/codex).
64+
65+
OpenUsage is a real-world example of what I teach in the [AI Builder's Blueprint](https://itsbyrob.in/EBDqgJ6) — a proven process for building and shipping software with AI, no coding background required.
66+
67+
## Sponsors
68+
69+
OpenUsage is supported by our sponsors. Become a sponsor to get your logo here and on [openusage.ai](https://openusage.ai).
70+
71+
[Become a Sponsor](https://github.com/sponsors/robinebers)
72+
73+
<!-- Add sponsor logos here -->
74+
75+
## Credits
76+
77+
Inspired by [CodexBar](https://github.com/steipete/CodexBar) by [@steipete](https://github.com/steipete). Same idea, very different approach.
78+
79+
## License
80+
81+
[MIT](LICENSE)
82+
83+
---
84+
85+
<details>
86+
<summary><strong>Build from source</strong></summary>
287

388
> **Warning**: The `main` branch may not be stable. It is merged directly without staging, so users are advised to use tagged versions for stable builds. Tagged versions are fully tested while `main` may contain unreleased features.
489

bun.lock

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
"@tauri-apps/plugin-process": "^2.3.1",
2828
"@tauri-apps/plugin-store": "^2.4.2",
2929
"@tauri-apps/plugin-updater": "^2.10.0",
30+
"@tauri-apps/plugin-global-shortcut": "^2",
3031
"class-variance-authority": "^0.7.1",
3132
"clsx": "^2.1.1",
3233
"lucide-react": "^0.563.0",

src-tauri/Cargo.lock

Lines changed: 74 additions & 7 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src-tauri/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ tauri-plugin-log = "2"
3535
tauri-plugin-aptabase = { git = "https://github.com/aptabase/tauri-plugin-aptabase", rev = "e896cceb" }
3636
tauri-plugin-updater = "2"
3737
tauri-plugin-process = "2"
38+
tauri-plugin-global-shortcut = "2"
3839
tokio = { version = "1", features = ["rt-multi-thread", "macros"] }
3940
regex-lite = "0.1.9"
4041

src-tauri/capabilities/default.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"store:default",
1616
"aptabase:allow-track-event",
1717
"updater:default",
18-
"process:allow-restart"
18+
"process:allow-restart",
19+
"global-shortcut:default"
1920
]
2021
}

0 commit comments

Comments
 (0)