@arittr/glorp 0.6.1 → 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.
Files changed (3) hide show
  1. package/README.md +15 -1
  2. package/bin/glorp.js +12 -0
  3. package/package.json +6 -6
package/README.md CHANGED
@@ -12,7 +12,21 @@ glorp init
12
12
  glorp watch
13
13
  ```
14
14
 
15
- The npm package bundles the native binary for your platform plus the `ccusage` and `@ccusage/codex` helpers, so no extra setup is needed.
15
+ The npm package bundles the native binary for your platform. Glorp's canonical
16
+ usage provider is `agentsview`; install it separately and make sure
17
+ `agentsview` is on `PATH`, or set `GLORP_AGENTSVIEW_BIN` to the executable
18
+ path. Glorp counts cached input fully so its visible totals match
19
+ Tokenmaxxing-style token totals.
20
+
21
+ | Var | Purpose |
22
+ |---|---|
23
+ | `GLORP_AGENTSVIEW_BIN` | Pin a specific `agentsview` binary for canonical Tokenmaxxing-compatible usage. |
24
+
25
+ ### Native macOS companion
26
+
27
+ On macOS, `glorp companion` opens the Dock-visible Glorp companion app. The
28
+ companion is a quiet round pet window for a normal display; detailed usage
29
+ diagnostics remain in `glorp watch`, `glorp status`, and `glorp doctor`.
16
30
 
17
31
  ## Privacy
18
32
 
package/bin/glorp.js CHANGED
@@ -55,6 +55,15 @@ function resolvePackageBin(pkg, binName) {
55
55
  }
56
56
  }
57
57
 
58
+ function resolveCompanionApp(env) {
59
+ if (env.GLORP_COMPANION_APP_FOR_TEST) return env.GLORP_COMPANION_APP_FOR_TEST;
60
+ if (process.platform !== "darwin") return undefined;
61
+ const pkgJson = resolvePackageJson(platformPackageName());
62
+ if (!pkgJson) return undefined;
63
+ const app = path.join(path.dirname(pkgJson), "app", "Glorp.app");
64
+ return fs.existsSync(app) ? app : undefined;
65
+ }
66
+
58
67
  const env = { ...process.env };
59
68
  if (env.GLORP_SKIP_BUNDLED_HELPERS_FOR_TEST !== "1") {
60
69
  env.GLORP_CCUSAGE_BIN ??= resolvePackageBin("ccusage", "ccusage");
@@ -62,6 +71,9 @@ if (env.GLORP_SKIP_BUNDLED_HELPERS_FOR_TEST !== "1") {
62
71
  }
63
72
  env.GLORP_NODE_BIN ??= process.execPath;
64
73
 
74
+ const companionApp = resolveCompanionApp(env);
75
+ if (companionApp) env.GLORP_COMPANION_APP ??= companionApp;
76
+
65
77
  let native;
66
78
  try {
67
79
  native = resolveNativeBinary(env);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arittr/glorp",
3
- "version": "0.6.1",
3
+ "version": "0.8.1",
4
4
  "description": "A terminal pet fed by real AI coding token usage",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -18,11 +18,11 @@
18
18
  "ccusage": "^18.0.11"
19
19
  },
20
20
  "optionalDependencies": {
21
- "@arittr/glorp-darwin-arm64": "0.6.1",
22
- "@arittr/glorp-darwin-x64": "0.6.1",
23
- "@arittr/glorp-linux-arm64": "0.6.1",
24
- "@arittr/glorp-linux-x64": "0.6.1",
25
- "@arittr/glorp-win32-x64": "0.6.1"
21
+ "@arittr/glorp-darwin-arm64": "0.8.1",
22
+ "@arittr/glorp-darwin-x64": "0.8.1",
23
+ "@arittr/glorp-linux-arm64": "0.8.1",
24
+ "@arittr/glorp-linux-x64": "0.8.1",
25
+ "@arittr/glorp-win32-x64": "0.8.1"
26
26
  },
27
27
  "scripts": {
28
28
  "test": "node test/smoke.mjs"