mirror of
https://github.com/sst/opencode.git
synced 2025-12-23 10:11:41 +00:00
ci: replace with just upload-artifact whole dir
Some checks are pending
deploy / deploy (push) Waiting to run
generate / generate (push) Waiting to run
publish / publish (push) Waiting to run
publish / publish-tauri (map[host:blacksmith-4vcpu-ubuntu-2404 target:x86_64-unknown-linux-gnu]) (push) Blocked by required conditions
publish / publish-tauri (map[host:blacksmith-4vcpu-windows-2025 target:x86_64-pc-windows-msvc]) (push) Blocked by required conditions
publish / publish-tauri (map[host:macos-latest target:aarch64-apple-darwin]) (push) Blocked by required conditions
publish / publish-tauri (map[host:macos-latest target:x86_64-apple-darwin]) (push) Blocked by required conditions
publish / publish-release (push) Blocked by required conditions
test / test (push) Waiting to run
Update Nix Hashes / update (push) Waiting to run
Some checks are pending
deploy / deploy (push) Waiting to run
generate / generate (push) Waiting to run
publish / publish (push) Waiting to run
publish / publish-tauri (map[host:blacksmith-4vcpu-ubuntu-2404 target:x86_64-unknown-linux-gnu]) (push) Blocked by required conditions
publish / publish-tauri (map[host:blacksmith-4vcpu-windows-2025 target:x86_64-pc-windows-msvc]) (push) Blocked by required conditions
publish / publish-tauri (map[host:macos-latest target:aarch64-apple-darwin]) (push) Blocked by required conditions
publish / publish-tauri (map[host:macos-latest target:x86_64-apple-darwin]) (push) Blocked by required conditions
publish / publish-release (push) Blocked by required conditions
test / test (push) Waiting to run
Update Nix Hashes / update (push) Waiting to run
This commit is contained in:
parent
92ade2a320
commit
68b09b30a1
1 changed files with 4 additions and 31 deletions
35
.github/workflows/publish.yml
vendored
35
.github/workflows/publish.yml
vendored
|
|
@ -69,19 +69,6 @@ jobs:
|
|||
git config --global user.name "opencode"
|
||||
git remote set-url origin https://x-access-token:${{ secrets.SST_GITHUB_TOKEN }}@github.com/${{ github.repository }}
|
||||
|
||||
- name: "Extract Actions runtime variables"
|
||||
id: extract-runtime-environment-variables
|
||||
uses: actions/github-script@v7
|
||||
env:
|
||||
github-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
script: |
|
||||
core.exportVariable('ACTIONS_RESULTS_URL', process.env['ACTIONS_RESULTS_URL'])
|
||||
core.exportVariable('ACTIONS_RUNTIME_URL', process.env['ACTIONS_RUNTIME_URL'])
|
||||
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env['ACTIONS_RUNTIME_TOKEN'])
|
||||
core.exportVariable('ACTIONS_CACHE_SERVICE_V2', process.env['ACTIONS_CACHE_SERVICE_V2'])
|
||||
core.exportVariable('ACTIONS_RESULTS_URL', process.env['ACTIONS_RESULTS_URL'])
|
||||
|
||||
- name: Publish
|
||||
id: publish
|
||||
run: ./script/publish-start.ts
|
||||
|
|
@ -93,24 +80,10 @@ jobs:
|
|||
GITHUB_TOKEN: ${{ secrets.SST_GITHUB_TOKEN }}
|
||||
NPM_CONFIG_PROVENANCE: false
|
||||
|
||||
- name: "Upload folders as artifacts"
|
||||
id: upload-artifacts
|
||||
shell: bun {0}
|
||||
working-directory: packages/opencode
|
||||
run: |
|
||||
import * as fs from 'fs/promises';
|
||||
import * as path from 'path';
|
||||
import { DefaultArtifactClient } from "@actions/artifact";
|
||||
import { $ } from "bun";
|
||||
|
||||
const artifactClient = new DefaultArtifactClient()
|
||||
|
||||
for await (const folder of $`ls ./dist`.lines()) {
|
||||
if (!folder.startsWith("opencode-")) continue
|
||||
|
||||
const files = await Array.fromAsync(await fs.glob(`./dist/${folder}/bin/*`))
|
||||
await artifactClient.uploadArtifact(folder, files, process.cwd())
|
||||
}
|
||||
- uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: opencode-cli
|
||||
path: packages/opencode/dist
|
||||
|
||||
outputs:
|
||||
release: ${{ steps.publish.outputs.release }}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue