@simonesiega/codex-limits 1.0.0 → 1.1.0
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/CHANGELOG.md +22 -0
- package/CONTRIBUTING.md +1 -1
- package/README.md +35 -12
- package/SECURITY.md +3 -3
- package/dist/cli.js +129 -129
- package/dist/copilot.mjs +3 -3
- package/dist/opencode.js +3 -3
- package/dist/pi.js +3 -3
- package/docs/readme/agent-integrations.md +1 -1
- package/docs/readme/agents/copilot.md +1 -1
- package/docs/readme/agents/opencode.md +2 -0
- package/docs/readme/agents/pi.md +1 -1
- package/docs/readme/compatibility.md +12 -10
- package/docs/readme/json-output.md +1 -1
- package/package.json +17 -4
- package/types/copilot.d.ts +6 -0
- package/types/opencode.d.ts +10 -0
- package/types/pi.d.ts +4 -0
- package/types/index.d.ts +0 -8
|
@@ -39,7 +39,7 @@ The installer writes one user-scoped extension entry point:
|
|
|
39
39
|
|
|
40
40
|
When `COPILOT_HOME` is set, the installer uses `extensions/codex-limits/extension.mjs` under that directory instead. The `codex-limits` subdirectory gives the extension its host-visible name.
|
|
41
41
|
|
|
42
|
-
The published package contains the bundled source at `dist/copilot.mjs`. The installer copies
|
|
42
|
+
The published package contains the bundled source at `dist/copilot.mjs` and exposes that host module as `@simonesiega/codex-limits/copilot`. The installer copies the same bundle to the ESM `extension.mjs` entry point. GitHub Copilot CLI starts it as a separate Node.js process and supplies `@github/copilot-sdk/extension` through its extension module resolver; users do not install the SDK separately. The package subpath is a host entry point, not an alternative installation command or a general-purpose JavaScript API.
|
|
43
43
|
|
|
44
44
|
The installer:
|
|
45
45
|
|
|
@@ -40,6 +40,8 @@ It adds the following package to each file's `plugin` array:
|
|
|
40
40
|
"@simonesiega/codex-limits"
|
|
41
41
|
```
|
|
42
42
|
|
|
43
|
+
The package root and the explicit `@simonesiega/codex-limits/opencode` host subpath resolve to the same bundled plugin. The installer uses the root package name for OpenCode plugin-loader compatibility; the subpath is not a separate installation method.
|
|
44
|
+
|
|
43
45
|
Both files are updated because compatible OpenCode versions discover TUI plugins through different global configuration files. The installer:
|
|
44
46
|
|
|
45
47
|
- creates a missing configuration as a JSON object with the appropriate OpenCode schema;
|
package/docs/readme/agents/pi.md
CHANGED
|
@@ -44,7 +44,7 @@ When `PI_CODING_AGENT_DIR` is set, the installer uses `settings.json` under that
|
|
|
44
44
|
}
|
|
45
45
|
```
|
|
46
46
|
|
|
47
|
-
Registering the local package root avoids another download and keeps the extension synchronized with the globally installed `codex-limits` package. The installer also recognizes existing unversioned, tagged, or pinned `npm:@simonesiega/codex-limits` pi package registrations. If a matching object registration filters out the bundled extension, the named installer force-enables only `dist/pi.js` while preserving unrelated resource filters.
|
|
47
|
+
Registering the local package root avoids another download and keeps the extension synchronized with the globally installed `codex-limits` package. The same host module is exposed explicitly as `@simonesiega/codex-limits/pi`, but pi installation continues to use the package manifest rather than that subpath directly. The installer also recognizes existing unversioned, tagged, or pinned `npm:@simonesiega/codex-limits` pi package registrations. If a matching object registration filters out the bundled extension, the named installer force-enables only `dist/pi.js` while preserving unrelated resource filters.
|
|
48
48
|
|
|
49
49
|
The installer:
|
|
50
50
|
|
|
@@ -16,22 +16,24 @@ This page describes the runtime, operating-system, Codex data, network, terminal
|
|
|
16
16
|
|
|
17
17
|
Bun is used for dependency management, tests, development commands, and production builds. It is not required to run the published CLI. Runtime dependencies are bundled into `dist`, so the published package does not declare separate production dependencies.
|
|
18
18
|
|
|
19
|
-
The root package module resolves to the agent-specific `dist/opencode.js` bundle for
|
|
19
|
+
The root package module resolves to the agent-specific `dist/opencode.js` bundle for OpenCode plugin-loader compatibility. The explicit `@simonesiega/codex-limits/opencode` subpath resolves to the same module; both expose a default plugin and the named `tui` export. The host-only `@simonesiega/codex-limits/pi` subpath resolves to the separate `dist/pi.js` extension also declared in the package's `pi.extensions` manifest. The host-only `@simonesiega/codex-limits/copilot` subpath resolves to the executable `dist/copilot.mjs` extension, which the GitHub Copilot CLI installer also copies to its recognized user extension entry point.
|
|
20
|
+
|
|
21
|
+
These agent-host exports are not a general-purpose JavaScript API and do not install an integration by themselves. The supported general interfaces are the CLI and its documented [JSON output](json-output.md). There is intentionally no `@simonesiega/codex-limits/core` export; internal core modules may change without a public API compatibility guarantee.
|
|
20
22
|
|
|
21
23
|
## Tested environments
|
|
22
24
|
|
|
23
25
|
The following environments are covered by the repository's automated checks or current local validation. Other compatible environments may also work, but they are not tested for every release.
|
|
24
26
|
|
|
25
|
-
| Area | Tested environments
|
|
26
|
-
| ---------------------- |
|
|
27
|
-
| Automated packaged CLI | GitHub Actions on `ubuntu-latest` with Node.js 20, 22, and 24,
|
|
28
|
-
| Current local checks | Windows build `10.0.26200.8875` with Node.js 22.20.0 and Bun 1.3.14 (verified 2026-07-23)
|
|
29
|
-
| Terminal rendering | Automated Ink rendering and layout tests; no named terminal application is included in the per-release test matrix
|
|
30
|
-
| OpenCode agent adapter | Mocked current keymap and legacy command API shapes; no exact OpenCode host release is tested end-to-end
|
|
31
|
-
| pi agent adapter | Mocked command/UI APIs with real TUI components; package discovery validated in pi 0.81.1 print mode
|
|
32
|
-
| Copilot CLI adapter | Mocked SDK command/timeline APIs and packed installation; typed against `@github/copilot-sdk` 1.0.8
|
|
27
|
+
| Area | Tested environments |
|
|
28
|
+
| ---------------------- | ----------------------------------------------------------------------------------------------------------------------------------- |
|
|
29
|
+
| Automated packaged CLI | GitHub Actions on `ubuntu-latest` with Node.js 20, 22, and 24, `windows-latest` with Node.js 20, and `macos-latest` with Node.js 22 |
|
|
30
|
+
| Current local checks | Windows build `10.0.26200.8875` with Node.js 22.20.0 and Bun 1.3.14 (verified 2026-07-23) |
|
|
31
|
+
| Terminal rendering | Automated Ink rendering and layout tests; no named terminal application is included in the per-release test matrix |
|
|
32
|
+
| OpenCode agent adapter | Mocked current keymap and legacy command API shapes; no exact OpenCode host release is tested end-to-end |
|
|
33
|
+
| pi agent adapter | Mocked command/UI APIs with real TUI components; package discovery validated in pi 0.81.1 print mode |
|
|
34
|
+
| Copilot CLI adapter | Mocked SDK command/timeline APIs and packed installation; typed against `@github/copilot-sdk` 1.0.8 |
|
|
33
35
|
|
|
34
|
-
The supported runtime and operating-system ranges are broader than this test matrix.
|
|
36
|
+
The supported runtime and operating-system ranges are broader than this test matrix. Automated checks sample each supported operating system but do not test every supported Node.js version on every platform.
|
|
35
37
|
|
|
36
38
|
## Operating systems
|
|
37
39
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@simonesiega/codex-limits",
|
|
3
|
-
"version": "1.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "Inspect Codex usage limits, reset times, and reset-credit coupons from the terminal, or explicitly confirm a remote usage reset.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"codex-limits": "dist/cli.js"
|
|
@@ -13,11 +13,23 @@
|
|
|
13
13
|
},
|
|
14
14
|
"exports": {
|
|
15
15
|
".": {
|
|
16
|
-
"types": "./types/
|
|
16
|
+
"types": "./types/opencode.d.ts",
|
|
17
17
|
"import": "./dist/opencode.js"
|
|
18
|
+
},
|
|
19
|
+
"./opencode": {
|
|
20
|
+
"types": "./types/opencode.d.ts",
|
|
21
|
+
"import": "./dist/opencode.js"
|
|
22
|
+
},
|
|
23
|
+
"./pi": {
|
|
24
|
+
"types": "./types/pi.d.ts",
|
|
25
|
+
"import": "./dist/pi.js"
|
|
26
|
+
},
|
|
27
|
+
"./copilot": {
|
|
28
|
+
"types": "./types/copilot.d.ts",
|
|
29
|
+
"import": "./dist/copilot.mjs"
|
|
18
30
|
}
|
|
19
31
|
},
|
|
20
|
-
"types": "./types/
|
|
32
|
+
"types": "./types/opencode.d.ts",
|
|
21
33
|
"files": [
|
|
22
34
|
"dist",
|
|
23
35
|
"types",
|
|
@@ -74,6 +86,7 @@
|
|
|
74
86
|
},
|
|
75
87
|
"packageManager": "bun@1.3.14",
|
|
76
88
|
"overrides": {
|
|
89
|
+
"brace-expansion": "5.0.9",
|
|
77
90
|
"fast-uri": "3.1.4"
|
|
78
91
|
},
|
|
79
92
|
"peerDependencies": {
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/** Public host-module contract exported from the Copilot-specific package subpath. */
|
|
2
|
+
export type CodexLimitsCopilotExtension = () => Promise<void>;
|
|
3
|
+
declare const plugin: CodexLimitsCopilotExtension;
|
|
4
|
+
export declare const COPILOT_EXTENSION_MARKER: "codex-limits-copilot-extension-v1";
|
|
5
|
+
export declare const startCopilotExtension: CodexLimitsCopilotExtension;
|
|
6
|
+
export default plugin;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** Public host-module contract exported from the OpenCode package entry points. */
|
|
2
|
+
export interface CodexLimitsTuiPluginModule {
|
|
3
|
+
id: "codex-limits";
|
|
4
|
+
tui: (api: unknown) => void | Promise<void>;
|
|
5
|
+
}
|
|
6
|
+
/** Agent-specific name for the original package-root contract. */
|
|
7
|
+
export type CodexLimitsOpencodeExtension = CodexLimitsTuiPluginModule;
|
|
8
|
+
declare const plugin: CodexLimitsTuiPluginModule;
|
|
9
|
+
export default plugin;
|
|
10
|
+
export declare const tui: CodexLimitsOpencodeExtension["tui"];
|
package/types/pi.d.ts
ADDED
package/types/index.d.ts
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
/** Public root-module contract loaded by OpenCode. */
|
|
2
|
-
export interface CodexLimitsTuiPluginModule {
|
|
3
|
-
id: "codex-limits";
|
|
4
|
-
tui: (api: unknown) => void | Promise<void>;
|
|
5
|
-
}
|
|
6
|
-
declare const plugin: CodexLimitsTuiPluginModule;
|
|
7
|
-
export default plugin;
|
|
8
|
-
export declare const tui: CodexLimitsTuiPluginModule["tui"];
|