@brainervirus/opencode-commandcode 0.6.0 → 0.6.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/CHANGELOG.md +25 -0
- package/README.md +1 -1
- package/manifest.json +1 -1
- package/package.json +1 -1
- package/src/catalog-release-notes.ts +3 -3
- package/src/cut-changelog.ts +40 -0
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,31 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.6.1] - 2026-08-28
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- semantic-release now cuts Keep a Changelog `[Unreleased]` into `## [version]` on publish and includes `CHANGELOG.md` in the post-release sync PR.
|
|
15
|
+
|
|
16
|
+
### Fixed
|
|
17
|
+
|
|
18
|
+
- Catalog GitHub release notes table no longer renders a blank header row above Plugin.
|
|
19
|
+
- Credits sentence no longer mentions Command Code wiring or restates MIT copyright.
|
|
20
|
+
|
|
21
|
+
## [0.6.0] - 2026-08-28
|
|
22
|
+
|
|
23
|
+
### Changed
|
|
24
|
+
|
|
25
|
+
- Renamed the published package and GitHub repository to `@brainervirus/opencode-commandcode`.
|
|
26
|
+
|
|
27
|
+
## [0.5.1] - 2026-08-28
|
|
28
|
+
|
|
29
|
+
### Fixed
|
|
30
|
+
|
|
31
|
+
- Price Command Code free SKUs at `$0` before models.dev, and fill remaining paid gaps from models.dev.
|
|
32
|
+
|
|
33
|
+
## [0.5.0] - 2026-08-28
|
|
34
|
+
|
|
10
35
|
### Added
|
|
11
36
|
|
|
12
37
|
- GitHub flow: PR-gated `main`, CI matrix (`check (test|typecheck|pack)`), semantic-release on merge, catalog updates as PRs.
|
package/README.md
CHANGED
|
@@ -12,7 +12,7 @@ Previously published as `@brainervirus/commandcode-go-opencode-provider`. Use th
|
|
|
12
12
|
|
|
13
13
|
## Credits
|
|
14
14
|
|
|
15
|
-
This package is based on **[FanFan4204/opencode-commandcode-provider](https://github.com/FanFan4204/opencode-commandcode-provider)**. That work started from **[brent-weatherall/opencode-commandcode-provider](https://github.com/brent-weatherall/opencode-commandcode-provider)** by **[Brent Weatherall](https://github.com/brent-weatherall)**. Thank you both — FanFan for the OpenCode provider this repo continues, and Brent for the original plugin, catalog extraction
|
|
15
|
+
This package is based on **[FanFan4204/opencode-commandcode-provider](https://github.com/FanFan4204/opencode-commandcode-provider)**. That work started from **[brent-weatherall/opencode-commandcode-provider](https://github.com/brent-weatherall/opencode-commandcode-provider)** by **[Brent Weatherall](https://github.com/brent-weatherall)**. Thank you both — FanFan for the OpenCode provider this repo continues, and Brent for the original plugin, catalog extraction.
|
|
16
16
|
|
|
17
17
|
### What this package adds
|
|
18
18
|
|
package/manifest.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"generatedAt": "2026-08-28T19:50:57.386Z",
|
|
4
|
-
"pluginVersion": "0.
|
|
4
|
+
"pluginVersion": "0.6.0",
|
|
5
5
|
"commandCodeVersion": "1.38.1",
|
|
6
6
|
"commandCodeTarball": "https://registry.npmjs.org/command-code/-/command-code-1.38.1.tgz",
|
|
7
7
|
"modelCount": 65,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@brainervirus/opencode-commandcode",
|
|
3
|
-
"version": "0.6.
|
|
3
|
+
"version": "0.6.1",
|
|
4
4
|
"description": "Command Code API provider for opencode — use Claude, GPT, Gemini, DeepSeek, Qwen, Kimi, GLM, MiniMax, and Step models via Command Code",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ai",
|
|
@@ -89,9 +89,8 @@ export function renderCatalogReleaseNotes(input: CatalogReleaseInput): string {
|
|
|
89
89
|
const sections = [
|
|
90
90
|
headline(input.status),
|
|
91
91
|
"",
|
|
92
|
-
"| | |",
|
|
93
|
-
"| --- | --- |",
|
|
94
92
|
`| Plugin | ${input.pluginVersion} |`,
|
|
93
|
+
"| --- | --- |",
|
|
95
94
|
`| Command Code | ${input.commandCodeVersion} |`,
|
|
96
95
|
`| Models | ${input.modelCount} (${input.reasoningModelCount} with reasoning) |`,
|
|
97
96
|
`| Prices | ${priceSummary(input.costSources)} |`,
|
|
@@ -157,9 +156,10 @@ export function renderCatalogReleaseNotes(input: CatalogReleaseInput): string {
|
|
|
157
156
|
export function catalogReleaseNotesFromFiles(input: {
|
|
158
157
|
manifest: CatalogManifest;
|
|
159
158
|
models: PricedModel[];
|
|
159
|
+
pluginVersion?: string;
|
|
160
160
|
}): string {
|
|
161
161
|
return renderCatalogReleaseNotes({
|
|
162
|
-
pluginVersion: input.manifest.pluginVersion,
|
|
162
|
+
pluginVersion: input.pluginVersion ?? input.manifest.pluginVersion,
|
|
163
163
|
commandCodeVersion: input.manifest.commandCodeVersion,
|
|
164
164
|
modelCount: input.manifest.modelCount,
|
|
165
165
|
reasoningModelCount: input.manifest.reasoningModelCount,
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
const UNRELEASED = /^## \[Unreleased\]\s*$/;
|
|
2
|
+
const VERSION = /^## \[/;
|
|
3
|
+
|
|
4
|
+
export function cutKeepAChangelog(markdown: string, version: string, date: string): string {
|
|
5
|
+
if (new RegExp(`^## \\[${escapeRegExp(version)}\\]`, "m").test(markdown)) return markdown;
|
|
6
|
+
|
|
7
|
+
const lines = markdown.split(/(?<=\n)/);
|
|
8
|
+
let start: number | null = null;
|
|
9
|
+
for (let i = 0; i < lines.length; i++) {
|
|
10
|
+
const line = lines[i];
|
|
11
|
+
if (line !== undefined && UNRELEASED.test(line.replace(/\n$/, ""))) {
|
|
12
|
+
start = i;
|
|
13
|
+
break;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
if (start === null) throw new Error("CHANGELOG.md has no ## [Unreleased] heading");
|
|
17
|
+
|
|
18
|
+
let end = lines.length;
|
|
19
|
+
for (let j = start + 1; j < lines.length; j++) {
|
|
20
|
+
const line = lines[j];
|
|
21
|
+
if (line === undefined) continue;
|
|
22
|
+
const stripped = line.replace(/\n$/, "");
|
|
23
|
+
if (VERSION.test(stripped) && !UNRELEASED.test(stripped)) {
|
|
24
|
+
end = j;
|
|
25
|
+
break;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
const before = lines.slice(0, start + 1).join("");
|
|
30
|
+
const body = lines
|
|
31
|
+
.slice(start + 1, end)
|
|
32
|
+
.join("")
|
|
33
|
+
.replace(/^\n+/, "\n");
|
|
34
|
+
const after = lines.slice(end).join("");
|
|
35
|
+
return `${before}\n## [${version}] - ${date}\n${body}${after}`;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
function escapeRegExp(value: string): string {
|
|
39
|
+
return value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
40
|
+
}
|