@vibe-cafe/vibe-usage 0.8.0 → 0.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +1 -1
- package/src/parsers/cursor.js +4 -0
- package/src/sync.js +4 -2
package/README.md
CHANGED
|
@@ -49,7 +49,7 @@ npx @vibe-cafe/vibe-usage status # Show config & detected tools
|
|
|
49
49
|
| Claude Code | `~/.claude/projects/` (tokens + sessions), `~/.claude/transcripts/` (sessions only) |
|
|
50
50
|
| Codex CLI | `~/.codex/sessions/` and `~/.codex/archived_sessions/` |
|
|
51
51
|
| GitHub Copilot CLI | `~/.copilot/session-state/*/events.jsonl` |
|
|
52
|
-
| Cursor | `state.vscdb` (SQLite, reads `cursorAuth/accessToken`, fetches CSV from `cursor.com`) |
|
|
52
|
+
| Cursor | `state.vscdb` (SQLite, reads `cursorAuth/accessToken`, fetches CSV from `cursor.com`); cloud data is stamped with a fixed `cursor-cloud` hostname so multi-machine setups don't double-count |
|
|
53
53
|
| Gemini CLI | `~/.gemini/tmp/` |
|
|
54
54
|
| OpenCode | `~/.local/share/opencode/opencode.db` (SQLite, `json_extract` query) |
|
|
55
55
|
| OpenClaw | `~/.openclaw/agents/`, `~/.openclaw-<profile>/agents/` (profile deployments) |
|
package/package.json
CHANGED
package/src/parsers/cursor.js
CHANGED
|
@@ -223,6 +223,10 @@ export async function parse() {
|
|
|
223
223
|
source: 'cursor',
|
|
224
224
|
model,
|
|
225
225
|
project: 'unknown',
|
|
226
|
+
// Cursor usage is pulled from the cloud API — it reflects the same account
|
|
227
|
+
// data on every machine. Use a fixed sentinel so all machines share one row
|
|
228
|
+
// per (model, bucket_start) rather than duplicating per hostname.
|
|
229
|
+
hostname: 'cursor-cloud',
|
|
226
230
|
timestamp,
|
|
227
231
|
inputTokens: inputCacheWrite + inputNoCache,
|
|
228
232
|
outputTokens: output,
|
package/src/sync.js
CHANGED
|
@@ -71,8 +71,10 @@ export async function runSync({ throws = false, quiet = false } = {}) {
|
|
|
71
71
|
config.hostname = host;
|
|
72
72
|
saveConfig(config);
|
|
73
73
|
}
|
|
74
|
-
|
|
75
|
-
|
|
74
|
+
// Cloud-sourced parsers (e.g. cursor) pre-set their own hostname sentinel so
|
|
75
|
+
// the same account data isn't stored as separate rows per machine.
|
|
76
|
+
for (const b of allBuckets) if (!b.hostname) b.hostname = host;
|
|
77
|
+
for (const s of allSessions) if (!s.hostname) s.hostname = host;
|
|
76
78
|
|
|
77
79
|
// Privacy: check if user allows project name upload
|
|
78
80
|
const apiUrl = config.apiUrl || 'https://vibecafe.ai';
|