diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 7a829a555..cfa5cd663 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -1,27 +1,22 @@ name: Bug Report -description: Report a bug or unexpected behavior in oh-my-opencode -title: "[Bug]: " +description: Report a bug or unexpected behavior in oh-my-openagent labels: ["bug", "needs-triage"] body: - type: markdown attributes: value: | - **Please write your issue in English.** See our [Language Policy](https://github.com/code-yeongyu/oh-my-opencode/blob/dev/CONTRIBUTING.md#language-policy) for details. - + **Please write your issue in English.** See our [Language Policy](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/CONTRIBUTING.md#language-policy) for details. - type: checkboxes id: prerequisites attributes: label: Prerequisites description: Please confirm the following before submitting options: - - label: I will write this issue in English (see our [Language Policy](https://github.com/code-yeongyu/oh-my-opencode/blob/dev/CONTRIBUTING.md#language-policy)) - required: true + - label: I will write this issue in English (see our [Language Policy](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/CONTRIBUTING.md#language-policy)) - label: I have searched existing issues to avoid duplicates required: true - - label: I am using the latest version of oh-my-opencode - required: true - - label: I have read the [documentation](https://github.com/code-yeongyu/oh-my-opencode#readme) or asked an AI coding agent with this project's GitHub URL loaded and couldn't find the answer - required: true + - label: I am using the latest version of oh-my-openagent + - label: I have read the [documentation](https://github.com/code-yeongyu/oh-my-openagent#readme) or asked an AI coding agent with this project's GitHub URL loaded and couldn't find the answer - type: textarea id: description @@ -38,8 +33,7 @@ body: label: Steps to Reproduce description: Steps to reproduce the behavior placeholder: | - 1. Configure oh-my-opencode with... - 2. Run command '...' + 1. Configure oh-my-openagent with... 3. See error... validations: required: true @@ -67,15 +61,12 @@ body: attributes: label: Doctor Output description: | - **Required:** Run `bunx oh-my-opencode doctor` and paste the full output below. - This helps us diagnose your environment and configuration. + **Required:** Run `bunx oh-my-openagent doctor` and paste the full output below. placeholder: | - Paste the output of: bunx oh-my-opencode doctor - + Paste the output of: bunx oh-my-openagent doctor Example: ✓ OpenCode version: 1.0.150 - ✓ oh-my-opencode version: 1.2.3 - ✓ Plugin loaded successfully + ✓ oh-my-openagent version: 1.2.3 ... render: shell validations: @@ -93,8 +84,7 @@ body: id: config attributes: label: Configuration - description: If relevant, share your oh-my-opencode configuration (remove sensitive data) - placeholder: | + description: If relevant, share your oh-my-openagent configuration (remove sensitive data) { "agents": { ... }, "disabled_hooks": [ ... ] diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index f161966eb..62820c1ea 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -4,5 +4,4 @@ contact_links: url: https://discord.gg/PUwSMR9XNk about: Join our Discord server for real-time discussions and community support - name: Documentation - url: https://github.com/code-yeongyu/oh-my-opencode#readme - about: Read the comprehensive documentation and guides + url: https://github.com/code-yeongyu/oh-my-openagent#readme diff --git a/.github/ISSUE_TEMPLATE/feature_request.yml b/.github/ISSUE_TEMPLATE/feature_request.yml index 448695101..6d8ad6db2 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.yml +++ b/.github/ISSUE_TEMPLATE/feature_request.yml @@ -1,27 +1,22 @@ name: Feature Request -description: Suggest a new feature or enhancement for oh-my-opencode -title: "[Feature]: " +description: Suggest a new feature or enhancement for oh-my-openagent labels: ["enhancement", "needs-triage"] body: - type: markdown attributes: value: | - **Please write your issue in English.** See our [Language Policy](https://github.com/code-yeongyu/oh-my-opencode/blob/dev/CONTRIBUTING.md#language-policy) for details. - + **Please write your issue in English.** See our [Language Policy](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/CONTRIBUTING.md#language-policy) for details. - type: checkboxes id: prerequisites attributes: label: Prerequisites description: Please confirm the following before submitting options: - - label: I will write this issue in English (see our [Language Policy](https://github.com/code-yeongyu/oh-my-opencode/blob/dev/CONTRIBUTING.md#language-policy)) - required: true + - label: I will write this issue in English (see our [Language Policy](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/CONTRIBUTING.md#language-policy)) - label: I have searched existing issues and discussions to avoid duplicates required: true - - label: This feature request is specific to oh-my-opencode (not OpenCode core) - required: true - - label: I have read the [documentation](https://github.com/code-yeongyu/oh-my-opencode#readme) or asked an AI coding agent with this project's GitHub URL loaded and couldn't find the answer - required: true + - label: This feature request is specific to oh-my-openagent (not OpenCode core) + - label: I have read the [documentation](https://github.com/code-yeongyu/oh-my-openagent#readme) or asked an AI coding agent with this project's GitHub URL loaded and couldn't find the answer - type: textarea id: problem @@ -59,11 +54,9 @@ body: attributes: label: Doctor Output (Optional) description: | - If relevant to your feature request, run `bunx oh-my-opencode doctor` and paste the output. - This helps us understand your environment. + If relevant to your feature request, run `bunx oh-my-openagent doctor` and paste the output. placeholder: | - Paste the output of: bunx oh-my-opencode doctor - (Optional for feature requests) + Paste the output of: bunx oh-my-openagent doctor render: shell - type: textarea diff --git a/.github/ISSUE_TEMPLATE/general.yml b/.github/ISSUE_TEMPLATE/general.yml index a219d6191..d98878484 100644 --- a/.github/ISSUE_TEMPLATE/general.yml +++ b/.github/ISSUE_TEMPLATE/general.yml @@ -1,25 +1,21 @@ name: Question or Discussion -description: Ask a question or start a discussion about oh-my-opencode -title: "[Question]: " +description: Ask a question or start a discussion about oh-my-openagent labels: ["question", "needs-triage"] body: - type: markdown attributes: value: | - **Please write your issue in English.** See our [Language Policy](https://github.com/code-yeongyu/oh-my-opencode/blob/dev/CONTRIBUTING.md#language-policy) for details. - + **Please write your issue in English.** See our [Language Policy](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/CONTRIBUTING.md#language-policy) for details. - type: checkboxes id: prerequisites attributes: label: Prerequisites description: Please confirm the following before submitting options: - - label: I will write this issue in English (see our [Language Policy](https://github.com/code-yeongyu/oh-my-opencode/blob/dev/CONTRIBUTING.md#language-policy)) - required: true + - label: I will write this issue in English (see our [Language Policy](https://github.com/code-yeongyu/oh-my-openagent/blob/dev/CONTRIBUTING.md#language-policy)) - label: I have searched existing issues and discussions required: true - - label: I have read the [documentation](https://github.com/code-yeongyu/oh-my-opencode#readme) or asked an AI coding agent with this project's GitHub URL loaded and couldn't find the answer - required: true + - label: I have read the [documentation](https://github.com/code-yeongyu/oh-my-openagent#readme) or asked an AI coding agent with this project's GitHub URL loaded and couldn't find the answer - label: This is a question (not a bug report or feature request) required: true @@ -53,10 +49,8 @@ body: attributes: label: Doctor Output (Optional) description: | - If your question is about configuration or setup, run `bunx oh-my-opencode doctor` and paste the output. - placeholder: | - Paste the output of: bunx oh-my-opencode doctor - (Optional for questions) + If your question is about configuration or setup, run `bunx oh-my-openagent doctor` and paste the output. + Paste the output of: bunx oh-my-openagent doctor render: shell - type: dropdown diff --git a/.github/workflows/cla.yml b/.github/workflows/cla.yml index 6b1a438db..b7c5acb6d 100644 --- a/.github/workflows/cla.yml +++ b/.github/workflows/cla.yml @@ -23,12 +23,10 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} with: path-to-signatures: 'signatures/cla.json' - path-to-document: 'https://github.com/code-yeongyu/oh-my-opencode/blob/master/CLA.md' - branch: 'dev' + path-to-document: 'https://github.com/code-yeongyu/oh-my-openagent/blob/master/CLA.md' allowlist: code-yeongyu,bot*,dependabot*,github-actions*,*[bot],sisyphus-dev-ai,web-flow custom-notsigned-prcomment: | - Thank you for your contribution! Before we can merge this PR, we need you to sign our [Contributor License Agreement (CLA)](https://github.com/code-yeongyu/oh-my-opencode/blob/master/CLA.md). - + Thank you for your contribution! Before we can merge this PR, we need you to sign our [Contributor License Agreement (CLA)](https://github.com/code-yeongyu/oh-my-openagent/blob/master/CLA.md). **To sign the CLA**, please comment on this PR with: ``` I have read the CLA Document and I hereby sign the CLA diff --git a/.github/workflows/publish-platform.yml b/.github/workflows/publish-platform.yml index 96f1be24b..4c2dd1173 100644 --- a/.github/workflows/publish-platform.yml +++ b/.github/workflows/publish-platform.yml @@ -59,39 +59,20 @@ jobs: - name: Check if already published id: check run: | + PKG_NAME="oh-my-opencode-${{ matrix.platform }}" VERSION="${{ inputs.version }}" + STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/${PKG_NAME}/${VERSION}") + # Convert platform name for output (replace - with _) PLATFORM_KEY="${{ matrix.platform }}" PLATFORM_KEY="${PLATFORM_KEY//-/_}" - - # Check oh-my-opencode - OC_STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-opencode-${{ matrix.platform }}/${VERSION}") - # Check oh-my-openagent - OA_STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-openagent-${{ matrix.platform }}/${VERSION}") - - echo "oh-my-opencode-${{ matrix.platform }}@${VERSION}: ${OC_STATUS}" - echo "oh-my-openagent-${{ matrix.platform }}@${VERSION}: ${OA_STATUS}" - - if [ "$OC_STATUS" = "200" ]; then - echo "skip_opencode=true" >> $GITHUB_OUTPUT - echo "✓ oh-my-opencode-${{ matrix.platform }}@${VERSION} already published" - else - echo "skip_opencode=false" >> $GITHUB_OUTPUT - echo "→ oh-my-opencode-${{ matrix.platform }}@${VERSION} needs publishing" - fi - - if [ "$OA_STATUS" = "200" ]; then - echo "skip_openagent=true" >> $GITHUB_OUTPUT - echo "✓ oh-my-openagent-${{ matrix.platform }}@${VERSION} already published" - else - echo "skip_openagent=false" >> $GITHUB_OUTPUT - echo "→ oh-my-openagent-${{ matrix.platform }}@${VERSION} needs publishing" - fi - - # Skip build only if BOTH are already published - if [ "$OC_STATUS" = "200" ] && [ "$OA_STATUS" = "200" ]; then + if [ "$STATUS" = "200" ]; then echo "skip=true" >> $GITHUB_OUTPUT + echo "skip_${PLATFORM_KEY}=true" >> $GITHUB_OUTPUT + echo "✓ ${PKG_NAME}@${VERSION} already published" else echo "skip=false" >> $GITHUB_OUTPUT + echo "skip_${PLATFORM_KEY}=false" >> $GITHUB_OUTPUT + echo "→ ${PKG_NAME}@${VERSION} needs publishing" fi - name: Update version in package.json @@ -216,6 +197,10 @@ jobs: retention-days: 1 if-no-files-found: error + # ============================================================================= + # Job 2: Publish all platforms (oh-my-openagent + oh-my-opencode) + # - Uses NODE_AUTH_TOKEN for auth + OIDC for provenance attestation + # ============================================================================= publish: needs: build if: always() && !cancelled() @@ -226,38 +211,35 @@ jobs: matrix: platform: [darwin-arm64, darwin-x64, darwin-x64-baseline, linux-x64, linux-x64-baseline, linux-arm64, linux-x64-musl, linux-x64-musl-baseline, linux-arm64-musl, windows-x64, windows-x64-baseline] steps: - - name: Check if already published + - name: Check if oh-my-openagent already published id: check run: | + PKG_NAME="oh-my-openagent-${{ matrix.platform }}" VERSION="${{ inputs.version }}" - - OC_STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-opencode-${{ matrix.platform }}/${VERSION}") - OA_STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-openagent-${{ matrix.platform }}/${VERSION}") - - if [ "$OC_STATUS" = "200" ]; then - echo "skip_opencode=true" >> $GITHUB_OUTPUT - echo "✓ oh-my-opencode-${{ matrix.platform }}@${VERSION} already published" + STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/${PKG_NAME}/${VERSION}") + if [ "$STATUS" = "200" ]; then + echo "skip=true" >> $GITHUB_OUTPUT + echo "✓ ${PKG_NAME}@${VERSION} already published, skipping" else - echo "skip_opencode=false" >> $GITHUB_OUTPUT + echo "→ ${PKG_NAME}@${VERSION} will be published" fi - - if [ "$OA_STATUS" = "200" ]; then - echo "skip_openagent=true" >> $GITHUB_OUTPUT - echo "✓ oh-my-openagent-${{ matrix.platform }}@${VERSION} already published" + + - name: Check if oh-my-opencode already published + id: check-openagent + run: | + PKG_NAME="oh-my-opencode-${{ matrix.platform }}" + VERSION="${{ inputs.version }}" + STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/${PKG_NAME}/${VERSION}") + if [ "$STATUS" = "200" ]; then + echo "skip=true" >> $GITHUB_OUTPUT + echo "✓ ${PKG_NAME}@${VERSION} already published, skipping" else - echo "skip_openagent=false" >> $GITHUB_OUTPUT - fi - - # Need artifact if either package needs publishing - if [ "$OC_STATUS" = "200" ] && [ "$OA_STATUS" = "200" ]; then - echo "skip_all=true" >> $GITHUB_OUTPUT - else - echo "skip_all=false" >> $GITHUB_OUTPUT + echo "→ ${PKG_NAME}@${VERSION} will be published" fi - name: Download artifact id: download - if: steps.check.outputs.skip_all != 'true' + if: steps.check.outputs.skip != 'true' || steps.check-openagent.outputs.skip != 'true' continue-on-error: true uses: actions/download-artifact@v4 with: @@ -265,7 +247,7 @@ jobs: path: . - name: Extract artifact - if: steps.check.outputs.skip_all != 'true' && steps.download.outcome == 'success' + if: (steps.check.outputs.skip != 'true' || steps.check-openagent.outputs.skip != 'true') && steps.download.outcome == 'success' run: | PLATFORM="${{ matrix.platform }}" mkdir -p packages/${PLATFORM} @@ -281,13 +263,12 @@ jobs: ls -la packages/${PLATFORM}/bin/ - uses: actions/setup-node@v4 - if: steps.check.outputs.skip_all != 'true' && steps.download.outcome == 'success' + if: (steps.check.outputs.skip != 'true' || steps.check-openagent.outputs.skip != 'true') && steps.download.outcome == 'success' with: node-version: "24" registry-url: "https://registry.npmjs.org" - - name: Publish oh-my-opencode-${{ matrix.platform }} - if: steps.check.outputs.skip_opencode != 'true' && steps.download.outcome == 'success' + - name: Publish oh-my-openagent-${{ matrix.platform }} run: | cd packages/${{ matrix.platform }} @@ -302,14 +283,14 @@ jobs: NPM_CONFIG_PROVENANCE: true timeout-minutes: 15 - - name: Publish oh-my-openagent-${{ matrix.platform }} - if: steps.check.outputs.skip_openagent != 'true' && steps.download.outcome == 'success' - run: | + - name: Publish oh-my-opencode-${{ matrix.platform }} (alias) cd packages/${{ matrix.platform }} - # Rename package for oh-my-openagent - jq --arg name "oh-my-openagent-${{ matrix.platform }}" \ - --arg desc "Platform-specific binary for oh-my-openagent (${{ matrix.platform }})" \ + # Rename package for oh-my-opencode + jq --arg name "oh-my-opencode-${{ matrix.platform }}" \ + --arg desc "Platform-specific binary for oh-my-opencode (${{ matrix.platform }})" \ + '.name = $name | .description = $desc | .bin = {"oh-my-opencode": (.bin | to_entries | .[0].value)}' \ + package.json > tmp.json && mv tmp.json package.json '.name = $name | .description = $desc | .bin = {"oh-my-openagent": (.bin | to_entries | .[0].value)}' \ package.json > tmp.json && mv tmp.json package.json diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index 32f44fbe3..eb8f99ca0 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -151,8 +151,7 @@ jobs: run: | VERSION="${{ inputs.version }}" if [ -z "$VERSION" ]; then - PREV=$(curl -s https://registry.npmjs.org/oh-my-opencode/latest | jq -r '.version // "0.0.0"') - BASE="${PREV%%-*}" + PREV=$(curl -s https://registry.npmjs.org/oh-my-openagent/latest | jq -r '.version // "0.0.0"') IFS='.' read -r MAJOR MINOR PATCH <<< "$BASE" case "${{ inputs.bump }}" in major) VERSION="$((MAJOR+1)).0.0" ;; @@ -174,11 +173,10 @@ jobs: - name: Check if already published id: check run: | - VERSION="${{ steps.version.outputs.version }}" - STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-opencode/${VERSION}") + STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-openagent/${VERSION}") if [ "$STATUS" = "200" ]; then echo "skip=true" >> $GITHUB_OUTPUT - echo "✓ oh-my-opencode@${VERSION} already published" + echo "✓ oh-my-openagent@${VERSION} already published" else echo "skip=false" >> $GITHUB_OUTPUT fi @@ -204,59 +202,91 @@ jobs: bunx tsc --emitDeclarationOnly bun run build:schema - - name: Publish oh-my-opencode + - name: Publish oh-my-openagent (primary) if: steps.check.outputs.skip != 'true' run: | - TAG_ARG="" - if [ -n "${{ steps.version.outputs.dist_tag }}" ]; then - TAG_ARG="--tag ${{ steps.version.outputs.dist_tag }}" - fi - npm publish --access public --provenance $TAG_ARG - env: - NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} - NPM_CONFIG_PROVENANCE: true - - - name: Check if oh-my-openagent already published - id: check-openagent - run: | - VERSION="${{ steps.version.outputs.version }}" - STATUS=$(curl -s -o /dev/null -w "%{http_code}" "https://registry.npmjs.org/oh-my-openagent/${VERSION}") - if [ "$STATUS" = "200" ]; then - echo "skip=true" >> $GITHUB_OUTPUT - echo "✓ oh-my-openagent@${VERSION} already published" - else - echo "skip=false" >> $GITHUB_OUTPUT - fi - - - name: Publish oh-my-openagent - if: steps.check-openagent.outputs.skip != 'true' - run: | - VERSION="${{ steps.version.outputs.version }}" + # Update package name to oh-my-openagent + jq '.name = "oh-my-openagent"' package.json > tmp.json && mv tmp.json package.json - # Update package name, version, and optionalDependencies for oh-my-openagent - jq --arg v "$VERSION" ' - .name = "oh-my-openagent" | - .version = $v | - .optionalDependencies = ( - .optionalDependencies | to_entries | - map(.key = (.key | sub("^oh-my-opencode-"; "oh-my-openagent-")) | .value = $v) | - from_entries - ) - ' package.json > tmp.json && mv tmp.json package.json + # Update optionalDependencies to use oh-my-openagent naming + jq '.optionalDependencies = { + "oh-my-openagent-darwin-arm64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-darwin-x64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-darwin-x64-baseline": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-arm64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-arm64-musl": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64-baseline": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64-musl": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64-musl-baseline": "${{ steps.version.outputs.version }}", + "oh-my-openagent-windows-x64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-windows-x64-baseline": "${{ steps.version.outputs.version }}" + }' package.json > tmp.json && mv tmp.json package.json TAG_ARG="" if [ -n "${{ steps.version.outputs.dist_tag }}" ]; then TAG_ARG="--tag ${{ steps.version.outputs.dist_tag }}" fi - npm publish --access public --provenance $TAG_ARG || echo "::warning::oh-my-openagent publish failed" env: NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} NPM_CONFIG_PROVENANCE: true - + - name: Publish oh-my-opencode (alias) + if: steps.check.outputs.skip != 'true' + run: | + # Update package name to oh-my-opencode + jq '.name = "oh-my-opencode"' package.json > tmp.json && mv tmp.json package.json + + # Update optionalDependencies to use oh-my-opencode naming + jq '.optionalDependencies = { + "oh-my-opencode-darwin-arm64": "${{ steps.version.outputs.version }}", + "oh-my-opencode-darwin-x64": "${{ steps.version.outputs.version }}", + "oh-my-opencode-darwin-x64-baseline": "${{ steps.version.outputs.version }}", + "oh-my-opencode-linux-arm64": "${{ steps.version.outputs.version }}", + "oh-my-opencode-linux-arm64-musl": "${{ steps.version.outputs.version }}", + "oh-my-opencode-linux-x64": "${{ steps.version.outputs.version }}", + "oh-my-opencode-linux-x64-baseline": "${{ steps.version.outputs.version }}", + "oh-my-opencode-linux-x64-musl": "${{ steps.version.outputs.version }}", + "oh-my-opencode-linux-x64-musl-baseline": "${{ steps.version.outputs.version }}", + "oh-my-opencode-windows-x64": "${{ steps.version.outputs.version }}", + "oh-my-opencode-windows-x64-baseline": "${{ steps.version.outputs.version }}" + }' package.json > tmp.json && mv tmp.json package.json + + TAG_ARG="" + if [ -n "${{ steps.version.outputs.dist_tag }}" ]; then + TAG_ARG="--tag ${{ steps.version.outputs.dist_tag }}" + fi + npm publish --access public --provenance $TAG_ARG || echo "oh-my-opencode alias publish may have failed (package may already exist)" + # Update package name to oh-my-openagent + jq '.name = "oh-my-openagent"' package.json > tmp.json && mv tmp.json package.json + + # Update optionalDependencies to use oh-my-openagent naming + jq '.optionalDependencies = { + "oh-my-openagent-darwin-arm64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-darwin-x64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-darwin-x64-baseline": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-arm64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-arm64-musl": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64-baseline": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64-musl": "${{ steps.version.outputs.version }}", + "oh-my-openagent-linux-x64-musl-baseline": "${{ steps.version.outputs.version }}", + "oh-my-openagent-windows-x64": "${{ steps.version.outputs.version }}", + "oh-my-openagent-windows-x64-baseline": "${{ steps.version.outputs.version }}" + }' package.json > tmp.json && mv tmp.json package.json + + TAG_ARG="" + if [ -n "${{ steps.version.outputs.dist_tag }}" ]; then + TAG_ARG="--tag ${{ steps.version.outputs.dist_tag }}" + fi + npm publish --access public --provenance $TAG_ARG || echo "oh-my-openagent publish may have failed (package may already exist)" + env: + NODE_AUTH_TOKEN: ${{ secrets.NODE_AUTH_TOKEN }} + NPM_CONFIG_PROVENANCE: true - name: Restore package.json - if: steps.check-openagent.outputs.skip != 'true' + if: steps.check.outputs.skip != 'true' run: | - git checkout -- package.json + # Restore original package name + jq '.name = "oh-my-opencode"' package.json > tmp.json && mv tmp.json package.json trigger-platform: runs-on: ubuntu-latest diff --git a/.github/workflows/sisyphus-agent.yml b/.github/workflows/sisyphus-agent.yml index 3d4f33cf1..bae8ebc6a 100644 --- a/.github/workflows/sisyphus-agent.yml +++ b/.github/workflows/sisyphus-agent.yml @@ -69,14 +69,14 @@ jobs: restore-keys: | ${{ runner.os }}-bun- - # Build local oh-my-opencode - - name: Build oh-my-opencode + # Build local oh-my-openagent + - name: Build oh-my-openagent run: | bun install bun run build # Install OpenCode + configure local plugin + auth in single step - - name: Setup OpenCode with oh-my-opencode + - name: Setup OpenCode with oh-my-openagent env: OPENCODE_AUTH_JSON: ${{ secrets.OPENCODE_AUTH_JSON }} ANTHROPIC_BASE_URL: ${{ secrets.ANTHROPIC_BASE_URL }} @@ -102,15 +102,14 @@ jobs: fi opencode --version - # Run local oh-my-opencode install (uses built dist) + # Run local oh-my-openagent install (uses built dist) bun run dist/cli/index.js install --no-tui --claude=max20 --openai=no --gemini=no --copilot=no # Override plugin to use local file reference OPENCODE_JSON=~/.config/opencode/opencode.json REPO_PATH=$(pwd) jq --arg path "file://$REPO_PATH/src/index.ts" ' - .plugin = [.plugin[] | select(. != "oh-my-opencode")] + [$path] - ' "$OPENCODE_JSON" > /tmp/oc.json && mv /tmp/oc.json "$OPENCODE_JSON" + .plugin = [.plugin[] | select(. != "oh-my-opencode" and . != "oh-my-openagent")] + [$path] OPENCODE_JSON=~/.config/opencode/opencode.json jq --arg baseURL "$ANTHROPIC_BASE_URL" --arg apiKey "$ANTHROPIC_API_KEY" ' @@ -190,7 +189,7 @@ jobs: } ' "$OPENCODE_JSON" > /tmp/oc.json && mv /tmp/oc.json "$OPENCODE_JSON" - OMO_JSON=~/.config/opencode/oh-my-opencode.json + OMO_JSON=~/.config/opencode/oh-my-openagent.json PROMPT_APPEND=$(cat << 'PROMPT_EOF' [CODE RED] Maximum precision required. Ultrathink before acting. @@ -397,7 +396,7 @@ jobs: --add-label "sisyphus: working" || true fi - - name: Run oh-my-opencode + - name: Run oh-my-openagent env: GITHUB_TOKEN: ${{ secrets.GH_PAT }} USER_COMMENT: ${{ steps.context.outputs.comment }}