Compare commits

..

49 Commits

Author SHA1 Message Date
Dax Raad
51f22c468d sync 2026-01-29 13:04:38 -05:00
Dax Raad
6b0336d475 sync 2026-01-29 13:03:28 -05:00
Dax Raad
5d5977cfef sync 2026-01-29 12:54:32 -05:00
Dax Raad
862597710f sync 2026-01-29 12:33:18 -05:00
Dax Raad
d48913b656 sync 2026-01-29 12:28:48 -05:00
Dax Raad
409a670177 sync 2026-01-29 12:27:25 -05:00
opencode
213070da0e release: v0.0.0-ci-202601291718 2026-01-29 12:25:30 -05:00
Dax Raad
5a1412cf0b sync 2026-01-29 12:25:30 -05:00
Dax Raad
f730ad508f sync 2026-01-29 12:25:30 -05:00
Dax Raad
e3d22489aa sync 2026-01-29 12:25:30 -05:00
Dax Raad
3bc291386e sync 2026-01-29 12:25:30 -05:00
Dax Raad
d479254a57 sync 2026-01-29 12:25:30 -05:00
Dax Raad
84bcb06698 sync 2026-01-29 12:25:30 -05:00
Dax Raad
a430f0c689 sync 2026-01-29 12:25:30 -05:00
Dax Raad
b74b444b45 sync 2026-01-29 12:25:30 -05:00
Dax Raad
fe6abe8ade sync 2026-01-29 12:25:30 -05:00
Dax Raad
76c002faf4 sync 2026-01-29 12:25:30 -05:00
Dax Raad
a2a828f423 sync 2026-01-29 12:25:30 -05:00
Dax Raad
7a4f63b22a sync 2026-01-29 12:25:30 -05:00
Dax Raad
88ed3f5605 sync 2026-01-29 12:25:30 -05:00
Dax Raad
6cf533b748 sync 2026-01-29 12:25:30 -05:00
Dax Raad
b5c9e7d6ce sync 2026-01-29 12:25:30 -05:00
Dax Raad
8bc3d01c75 sync 2026-01-29 12:25:30 -05:00
Dax Raad
6f0b8c19dd sync 2026-01-29 12:25:30 -05:00
Dax Raad
a3f27dd924 sync 2026-01-29 12:25:30 -05:00
Dax Raad
0cf04a0295 sync 2026-01-29 12:25:30 -05:00
Dax Raad
a5fbb5dbec sync 2026-01-29 12:25:30 -05:00
Dax Raad
dfbf5d38f9 sync 2026-01-29 12:25:30 -05:00
Dax Raad
cbcbbe04ef sync 2026-01-29 12:25:30 -05:00
Dax Raad
8e3e208917 sync 2026-01-29 12:25:30 -05:00
Dax Raad
be2b368507 sync 2026-01-29 12:25:30 -05:00
Dax Raad
128e812500 sync 2026-01-29 12:25:30 -05:00
Dax Raad
1a3f4723e1 sync 2026-01-29 12:25:30 -05:00
Dax Raad
fd8177dad9 sync 2026-01-29 12:25:30 -05:00
Dax Raad
568a235445 sync 2026-01-29 12:25:30 -05:00
Dax Raad
9166c6e0f5 sync 2026-01-29 12:25:30 -05:00
Dax Raad
e84a8d9b19 sync 2026-01-29 12:25:30 -05:00
Dax Raad
564d373dd2 sync 2026-01-29 12:25:30 -05:00
Dax Raad
c62149129f sync 2026-01-29 12:25:30 -05:00
Dax Raad
e56016fd21 sync 2026-01-29 12:25:30 -05:00
Dax Raad
221e3182ca sync 2026-01-29 12:25:30 -05:00
Dax Raad
06399f21b4 sync 2026-01-29 12:25:30 -05:00
Dax Raad
96212f15fc sync 2026-01-29 12:25:30 -05:00
Dax Raad
26142b0deb sync 2026-01-29 12:25:30 -05:00
Dax Raad
1d972d6bae sync 2026-01-29 12:25:30 -05:00
Aiden Cline
aa92ef37fd tweak: add 'skill' to permissions config section so that ides will show it as autocomplete option (this is already a respected setting) 2026-01-29 10:55:39 -06:00
Goni Zahavy
d5c59a66c1 ci: added gh workflow that adds 'contributor' label to PRs/Issues (#11118)
Co-authored-by: Aiden Cline <63023139+rekram1-node@users.noreply.github.com>
2026-01-29 10:38:08 -06:00
Aiden Cline
301895c7f7 fix: ensure kimi k2.5 from fireworks ai and kimi for coding providers properly set temperature 2026-01-29 10:30:22 -06:00
Ravi Kumar
03ba49af4e fix(telemetry): restore userId and sessionId metadata in experimental_telemetry (#8195) 2026-01-29 10:14:28 -06:00
29 changed files with 143 additions and 146 deletions

View File

@@ -0,0 +1,33 @@
name: Add Contributors Label
on:
# issues:
# types: [opened]
pull_request_target:
types: [opened]
jobs:
add-contributor-label:
runs-on: ubuntu-latest
permissions:
pull-requests: write
issues: write
steps:
- name: Add Contributor Label
uses: actions/github-script@v8
with:
script: |
const isPR = !!context.payload.pull_request;
const issueNumber = isPR ? context.payload.pull_request.number : context.payload.issue.number;
const authorAssociation = isPR ? context.payload.pull_request.author_association : context.payload.issue.author_association;
if (authorAssociation === 'CONTRIBUTOR') {
await github.rest.issues.addLabels({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: issueNumber,
labels: ['contributor']
});
}

View File

@@ -36,7 +36,7 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
fetch-depth: 1
- uses: ./.github/actions/setup-bun
- id: version
run: |
@@ -57,9 +57,8 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- run: git fetch --force --tags
fetch-depth: 1
fetch-tags: true
- uses: ./.github/actions/setup-bun
@@ -69,6 +68,8 @@ jobs:
./packages/opencode/script/build.ts
env:
OPENCODE_VERSION: ${{ needs.version.outputs.version }}
OPENCODE_RELEASE: ${{ needs.version.outputs.release }}
GH_TOKEN: ${{ github.token }}
- uses: actions/upload-artifact@v4
with:
@@ -79,7 +80,6 @@ jobs:
version: ${{ needs.version.outputs.version }}
build-tauri:
if: false
needs:
- build-cli
- version
@@ -102,7 +102,8 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
fetch-depth: 1
fetch-tags: true
- uses: apple-actions/import-codesign-certs@v2
if: ${{ runner.os == 'macOS' }}
@@ -124,8 +125,6 @@ jobs:
run: |
echo "${{ secrets.APPLE_API_KEY_PATH }}" > $RUNNER_TEMP/apple-api-key.p8
- run: git fetch --force --tags
- uses: ./.github/actions/setup-bun
- name: install dependencies (ubuntu only)
@@ -164,22 +163,18 @@ jobs:
cargo tauri --version
- name: Build and upload artifacts
uses: Wandalen/wretry.action@v3
uses: tauri-apps/tauri-action@390cbe447412ced1303d35abe75287949e43437a
timeout-minutes: 60
with:
attempt_limit: 3
attempt_delay: 10000
action: tauri-apps/tauri-action@390cbe447412ced1303d35abe75287949e43437a
with: |
projectPath: packages/desktop
uploadWorkflowArtifacts: true
tauriScript: ${{ (contains(matrix.settings.host, 'ubuntu') && 'cargo tauri') || '' }}
args: --target ${{ matrix.settings.target }} --config ./src-tauri/tauri.prod.conf.json --verbose
updaterJsonPreferNsis: true
releaseId: ${{ needs.version.outputs.release }}
tagName: ${{ needs.version.outputs.tag }}
releaseDraft: true
releaseAssetNamePattern: opencode-desktop-[platform]-[arch][ext]
projectPath: packages/desktop
uploadWorkflowArtifacts: true
tauriScript: ${{ (contains(matrix.settings.host, 'ubuntu') && 'cargo tauri') || '' }}
args: --target ${{ matrix.settings.target }} --config ./src-tauri/tauri.prod.conf.json --verbose
updaterJsonPreferNsis: true
releaseId: ${{ needs.version.outputs.release }}
tagName: ${{ needs.version.outputs.tag }}
releaseDraft: true
releaseAssetNamePattern: opencode-desktop-[platform]-[arch][ext]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
TAURI_BUNDLER_NEW_APPIMAGE_FORMAT: true
@@ -194,12 +189,14 @@ jobs:
publish:
needs:
- version
- build-cli
- build-tauri
runs-on: blacksmith-4vcpu-ubuntu-2404
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
fetch-depth: 1
- name: Install OpenCode
if: inputs.bump || inputs.version
@@ -228,10 +225,6 @@ jobs:
git config --global user.email "opencode@sst.dev"
git config --global user.name "opencode"
git remote set-url origin https://x-access-token:${{ secrets.SST_GITHUB_TOKEN }}@github.com/${{ github.repository }}
- uses: actions/checkout@v3
with:
fetch-depth: 0
ref: ${{ needs.version.outputs.tag }}
- uses: ./.github/actions/setup-bun
@@ -240,13 +233,6 @@ jobs:
name: opencode-cli
path: packages/opencode/dist
- name: Make binaries executable
run: |
echo "Adding execute permissions to all binaries..."
find packages/opencode/dist -type f \( -name "opencode" -o -name "opencode.exe" \) -exec chmod +x {} \;
echo "Permissions after fix:"
find packages/opencode/dist -type f -name "opencode" | head -3 | xargs ls -la
- name: Setup SSH for AUR
run: |
sudo apt-get update
@@ -261,7 +247,7 @@ jobs:
- run: ./script/publish.ts
env:
OPENCODE_VERSION: ${{ needs.version.outputs.version }}
OPENCODE_RELEASE_ID: ${{ needs.version.outputs.release }}
OPENCODE_RELEASE: ${{ needs.version.outputs.release }}
AUR_KEY: ${{ secrets.AUR_KEY }}
GITHUB_TOKEN: ${{ secrets.SST_GITHUB_TOKEN }}
OPENCODE_API_KEY: ${{ secrets.OPENCODE_API_KEY }}

View File

@@ -23,7 +23,7 @@
},
"packages/app": {
"name": "@opencode-ai/app",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@kobalte/core": "catalog:",
"@opencode-ai/sdk": "workspace:*",
@@ -73,7 +73,7 @@
},
"packages/console/app": {
"name": "@opencode-ai/console-app",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@cloudflare/vite-plugin": "1.15.2",
"@ibm/plex": "6.4.1",
@@ -107,7 +107,7 @@
},
"packages/console/core": {
"name": "@opencode-ai/console-core",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@aws-sdk/client-sts": "3.782.0",
"@jsx-email/render": "1.1.1",
@@ -134,7 +134,7 @@
},
"packages/console/function": {
"name": "@opencode-ai/console-function",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@ai-sdk/anthropic": "2.0.0",
"@ai-sdk/openai": "2.0.2",
@@ -158,7 +158,7 @@
},
"packages/console/mail": {
"name": "@opencode-ai/console-mail",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@jsx-email/all": "2.2.3",
"@jsx-email/cli": "1.4.3",
@@ -182,7 +182,7 @@
},
"packages/desktop": {
"name": "@opencode-ai/desktop",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@opencode-ai/app": "workspace:*",
"@opencode-ai/ui": "workspace:*",
@@ -213,7 +213,7 @@
},
"packages/enterprise": {
"name": "@opencode-ai/enterprise",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@opencode-ai/ui": "workspace:*",
"@opencode-ai/util": "workspace:*",
@@ -242,7 +242,7 @@
},
"packages/function": {
"name": "@opencode-ai/function",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@octokit/auth-app": "8.0.1",
"@octokit/rest": "catalog:",
@@ -258,7 +258,7 @@
},
"packages/opencode": {
"name": "opencode",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"bin": {
"opencode": "./bin/opencode",
},
@@ -362,7 +362,7 @@
},
"packages/plugin": {
"name": "@opencode-ai/plugin",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@opencode-ai/sdk": "workspace:*",
"zod": "catalog:",
@@ -382,7 +382,7 @@
},
"packages/sdk/js": {
"name": "@opencode-ai/sdk",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"devDependencies": {
"@hey-api/openapi-ts": "0.90.10",
"@tsconfig/node22": "catalog:",
@@ -393,7 +393,7 @@
},
"packages/slack": {
"name": "@opencode-ai/slack",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@opencode-ai/sdk": "workspace:*",
"@slack/bolt": "^3.17.1",
@@ -406,7 +406,7 @@
},
"packages/ui": {
"name": "@opencode-ai/ui",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@kobalte/core": "catalog:",
"@opencode-ai/sdk": "workspace:*",
@@ -448,7 +448,7 @@
},
"packages/util": {
"name": "@opencode-ai/util",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"zod": "catalog:",
},
@@ -459,7 +459,7 @@
},
"packages/web": {
"name": "@opencode-ai/web",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@astrojs/cloudflare": "12.6.3",
"@astrojs/markdown-remark": "6.3.1",

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/app",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"description": "",
"type": "module",
"exports": {

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/console-app",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"type": "module",
"license": "MIT",
"scripts": {

View File

@@ -1,7 +1,7 @@
{
"$schema": "https://json.schemastore.org/package.json",
"name": "@opencode-ai/console-core",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"private": true,
"type": "module",
"license": "MIT",

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/console-function",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"$schema": "https://json.schemastore.org/package.json",
"private": true,
"type": "module",

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/console-mail",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"dependencies": {
"@jsx-email/all": "2.2.3",
"@jsx-email/cli": "1.4.3",

View File

@@ -1,7 +1,7 @@
{
"name": "@opencode-ai/desktop",
"private": true,
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"type": "module",
"license": "MIT",
"scripts": {

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/enterprise",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"private": true,
"type": "module",
"license": "MIT",

View File

@@ -1,7 +1,7 @@
id = "opencode"
name = "OpenCode"
description = "The open source coding agent."
version = "0.0.0-ci-202601291635"
version = "0.0.0-ci-202601291718"
schema_version = 1
authors = ["Anomaly"]
repository = "https://github.com/anomalyco/opencode"
@@ -11,26 +11,26 @@ name = "OpenCode"
icon = "./icons/opencode.svg"
[agent_servers.opencode.targets.darwin-aarch64]
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291635/opencode-darwin-arm64.zip"
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291718/opencode-darwin-arm64.zip"
cmd = "./opencode"
args = ["acp"]
[agent_servers.opencode.targets.darwin-x86_64]
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291635/opencode-darwin-x64.zip"
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291718/opencode-darwin-x64.zip"
cmd = "./opencode"
args = ["acp"]
[agent_servers.opencode.targets.linux-aarch64]
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291635/opencode-linux-arm64.tar.gz"
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291718/opencode-linux-arm64.tar.gz"
cmd = "./opencode"
args = ["acp"]
[agent_servers.opencode.targets.linux-x86_64]
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291635/opencode-linux-x64.tar.gz"
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291718/opencode-linux-x64.tar.gz"
cmd = "./opencode"
args = ["acp"]
[agent_servers.opencode.targets.windows-x86_64]
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291635/opencode-windows-x64.zip"
archive = "https://github.com/anomalyco/opencode/releases/download/v0.0.0-ci-202601291718/opencode-windows-x64.zip"
cmd = "./opencode.exe"
args = ["acp"]

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/function",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"$schema": "https://json.schemastore.org/package.json",
"private": true,
"type": "module",

View File

@@ -1,6 +1,6 @@
{
"$schema": "https://json.schemastore.org/package.json",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"name": "opencode",
"type": "module",
"license": "MIT",

View File

@@ -179,4 +179,15 @@ for (const item of targets) {
binaries[name] = Script.version
}
if (Script.release) {
for (const key of Object.keys(binaries)) {
if (key.includes("linux")) {
await $`tar -czf ../../${key}.tar.gz *`.cwd(`dist/${key}/bin`)
} else {
await $`zip -r ../../${key}.zip *`.cwd(`dist/${key}/bin`)
}
}
await $`gh release upload v${Script.version} ./dist/*.zip ./dist/*.tar.gz --clobber`
}
export { binaries }

View File

@@ -15,12 +15,6 @@ for (const filepath of new Bun.Glob("*/package.json").scanSync({ cwd: "./dist" }
console.log("binaries", binaries)
const version = Object.values(binaries)[0]
{
const name = `${pkg.name}-${process.platform}-${process.arch}`
console.log(`smoke test: running dist/${name}/bin/opencode --version`)
await $`./dist/${name}/bin/opencode --version`
}
await $`mkdir -p ./dist/${pkg.name}`
await $`cp -r ./bin ./dist/${pkg.name}/bin`
await $`cp ./script/postinstall.mjs ./dist/${pkg.name}/postinstall.mjs`
@@ -43,38 +37,21 @@ await Bun.file(`./dist/${pkg.name}/package.json`).write(
),
)
const tags = [Script.channel]
const tasks = Object.entries(binaries).map(async ([name]) => {
if (process.platform !== "win32") {
await $`chmod -R 755 .`.cwd(`./dist/${name}`)
}
await $`bun pm pack`.cwd(`./dist/${name}`)
for (const tag of tags) {
await $`npm publish *.tgz --access public --tag ${tag}`.cwd(`./dist/${name}`)
}
await $`npm publish *.tgz --access public --tag ${Script.channel}`.cwd(`./dist/${name}`)
})
await Promise.all(tasks)
for (const tag of tags) {
await $`cd ./dist/${pkg.name} && bun pm pack && npm publish *.tgz --access public --tag ${tag}`
}
await $`cd ./dist/${pkg.name} && bun pm pack && npm publish *.tgz --access public --tag ${Script.channel}`
if (!Script.preview) {
// Create archives for GitHub release
for (const key of Object.keys(binaries)) {
if (key.includes("linux")) {
await $`tar -czf ../../${key}.tar.gz *`.cwd(`dist/${key}/bin`)
} else {
await $`zip -r ../../${key}.zip *`.cwd(`dist/${key}/bin`)
}
}
const image = "ghcr.io/anomalyco/opencode"
const platforms = "linux/amd64,linux/arm64"
const tags = [`${image}:${version}`, `${image}:latest`]
const tagFlags = tags.flatMap((t) => ["-t", t])
await $`docker buildx build --platform ${platforms} ${tagFlags} --push .`
}
const image = "ghcr.io/anomalyco/opencode"
const platforms = "linux/amd64,linux/arm64"
const tags = [`${image}:${version}`, `${image}:${Script.channel}`]
const tagFlags = tags.flatMap((t) => ["-t", t])
await $`docker buildx build --platform ${platforms} ${tagFlags} --push .`
// registries
if (!Script.preview) {

View File

@@ -540,6 +540,7 @@ export namespace Config {
codesearch: PermissionAction.optional(),
lsp: PermissionRule.optional(),
doom_loop: PermissionAction.optional(),
skill: PermissionRule.optional(),
})
.catchall(PermissionRule)
.or(PermissionAction),

View File

@@ -284,8 +284,8 @@ export namespace ProviderTransform {
if (id.includes("glm-4.7")) return 1.0
if (id.includes("minimax-m2")) return 1.0
if (id.includes("kimi-k2")) {
// kimi-k2-thinking & kimi-k2.5
if (id.includes("thinking") || id.includes("k2.")) {
// kimi-k2-thinking & kimi-k2.5 && kimi-k2p5
if (id.includes("thinking") || id.includes("k2.") || id.includes("k2p")) {
return 1.0
}
return 0.6
@@ -296,7 +296,7 @@ export namespace ProviderTransform {
export function topP(model: Provider.Model) {
const id = model.id.toLowerCase()
if (id.includes("qwen")) return 1
if (id.includes("minimax-m2") || id.includes("kimi-k2.5") || id.includes("gemini")) {
if (id.includes("minimax-m2") || id.includes("kimi-k2.5") || id.includes("kimi-k2p5") || id.includes("gemini")) {
return 0.95
}
return undefined

View File

@@ -264,7 +264,13 @@ export namespace LLM {
extractReasoningMiddleware({ tagName: "think", startWithReasoning: false }),
],
}),
experimental_telemetry: { isEnabled: cfg.experimental?.openTelemetry },
experimental_telemetry: {
isEnabled: cfg.experimental?.openTelemetry,
metadata: {
userId: cfg.username ?? "unknown",
sessionId: input.sessionID,
},
},
})
}

View File

@@ -1,7 +1,7 @@
{
"$schema": "https://json.schemastore.org/package.json",
"name": "@opencode-ai/plugin",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"type": "module",
"license": "MIT",
"scripts": {

View File

@@ -20,6 +20,7 @@ const env = {
OPENCODE_CHANNEL: process.env["OPENCODE_CHANNEL"],
OPENCODE_BUMP: process.env["OPENCODE_BUMP"],
OPENCODE_VERSION: process.env["OPENCODE_VERSION"],
OPENCODE_RELEASE: process.env["OPENCODE_RELEASE"],
}
const CHANNEL = await (async () => {
if (env.OPENCODE_CHANNEL) return env.OPENCODE_CHANNEL
@@ -55,5 +56,8 @@ export const Script = {
get preview() {
return IS_PREVIEW
},
get release() {
return env.OPENCODE_RELEASE
},
}
console.log(`opencode script`, JSON.stringify(Script, null, 2))

View File

@@ -1,7 +1,7 @@
{
"$schema": "https://json.schemastore.org/package.json",
"name": "@opencode-ai/sdk",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"type": "module",
"license": "MIT",
"scripts": {

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/slack",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"type": "module",
"license": "MIT",
"scripts": {

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/ui",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"type": "module",
"license": "MIT",
"exports": {

View File

@@ -1,6 +1,6 @@
{
"name": "@opencode-ai/util",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"private": true,
"type": "module",
"license": "MIT",

View File

@@ -2,7 +2,7 @@
"name": "@opencode-ai/web",
"type": "module",
"license": "MIT",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"scripts": {
"dev": "astro dev",
"dev:remote": "VITE_API_URL=https://api.opencode.ai astro dev",

View File

@@ -1,14 +0,0 @@
#!/usr/bin/env bun
import { Script } from "@opencode-ai/script"
import { $ } from "bun"
if (!Script.preview) {
await $`gh release edit v${Script.version} --draft=false`
}
await $`bun install`
await $`gh release download --pattern "opencode-linux-*64.tar.gz" --pattern "opencode-darwin-*64.zip" -D dist`
await import(`../packages/opencode/script/publish-registries.ts`)

View File

@@ -32,16 +32,8 @@ Add highlights before publishing. Delete this section if no highlights.
`
let notes: string[] = []
console.log("=== publishing ===\n")
if (!Script.preview) {
const previous = await getLatestRelease()
notes = await buildNotes(previous, "HEAD")
// notes.unshift(highlightsTemplate)
}
const pkgjsons = await Array.fromAsync(
new Bun.Glob("**/package.json").scan({
absolute: true,
@@ -65,20 +57,19 @@ await Bun.file(extensionToml).write(toml)
await $`bun install`
await import(`../packages/sdk/js/script/build.ts`)
await $`git commit -am "release: v${Script.version}"`
await $`git tag v${Script.version}`
await $`git fetch origin`
await $`git cherry-pick HEAD..origin/dev`.nothrow()
await $`git push origin HEAD --tags --no-verify --force-with-lease`
await new Promise((resolve) => setTimeout(resolve, 5_000))
const releaseID = process.env.OPENCODE_RELEASE_ID
if (!releaseID) {
throw new Error("OPENCODE_RELEASE_ID environment variable is required")
if (Script.release) {
const previous = await getLatestRelease()
const notes = await buildNotes(previous, "HEAD")
// notes.unshift(highlightsTemplate)
await $`git commit -am "release: v${Script.version}"`
await $`git tag v${Script.version}`
await $`git fetch origin`
await $`git cherry-pick HEAD..origin/dev`.nothrow()
await $`git push origin HEAD --tags --no-verify --force-with-lease`
await new Promise((resolve) => setTimeout(resolve, 5_000))
await $`gh release edit v${Script.version} --draft=false --title "v${Script.version}" --notes ${notes.join("\n") || "No notable changes"}`
}
await $`gh release edit ${releaseID} --draft --title "v${Script.version}" --notes ${notes.join("\n") || "No notable changes"}`
await $`gh release upload v${Script.version} ./packages/opencode/dist/*.zip ./packages/opencode/dist/*.tar.gz --clobber`
console.log("\n=== cli ===\n")
await import(`../packages/opencode/script/publish.ts`)

View File

@@ -3,13 +3,15 @@
import { Script } from "@opencode-ai/script"
import { $ } from "bun"
let output = `version=${Script.version}\n`
let output = [`version=${Script.version}`]
await $`gh release create v${Script.version} -d --title "v${Script.version}" ${Script.preview ? "--prerelease" : ""}`
const release = await $`gh release view v${Script.version} --json id,tagName`.json()
output += `release=${release.id}\n`
output += `tag=${release.tagName}\n`
if (!Script.preview) {
await $`gh release create v${Script.version} -d --title "v${Script.version}" ${Script.preview ? "--prerelease" : ""}`
const release = await $`gh release view v${Script.version} --json id,tagName`.json()
output.push(`release=${release.id}`)
output.push(`tag=${release.tagName}`)
}
if (process.env.GITHUB_OUTPUT) {
await Bun.write(process.env.GITHUB_OUTPUT, output)
await Bun.write(process.env.GITHUB_OUTPUT, output.join("\n"))
}

View File

@@ -2,7 +2,7 @@
"name": "opencode",
"displayName": "opencode",
"description": "opencode for VS Code",
"version": "0.0.0-ci-202601291635",
"version": "0.0.0-ci-202601291718",
"publisher": "sst-dev",
"repository": {
"type": "git",