diff --git a/.github/workflows/extension-release.yml b/.github/workflows/extension-release.yml index d9240e3..aa2c0ce 100755 --- a/.github/workflows/extension-release.yml +++ b/.github/workflows/extension-release.yml @@ -2,7 +2,15 @@ name: Extension Release on: + workflow_dispatch: + inputs: + version: + description: Extension version to validate + required: true + type: string push: + branches: + - codex/ext-release-validation tags: - "ext-v*" @@ -14,6 +22,7 @@ jobs: runs-on: windows-latest env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_REF_NAME_OVERRIDE: ${{ startsWith(github.ref, 'refs/tags/') && github.ref_name || format('ext-v{0}', inputs.version || '2.8.1') }} steps: - uses: actions/checkout@v4 with: @@ -35,8 +44,9 @@ jobs: shell: bash run: | set -euo pipefail - ./target/release/marqdo.exe call skills/marqdo-release/packs.mq.md ci --effects plugin,fs.read,fs.write,environment.read --fs-root . --require-ok --json + GITHUB_REF_NAME="$GITHUB_REF_NAME_OVERRIDE" ./target/release/marqdo.exe call skills/marqdo-release/packs.mq.md ci --effects plugin,fs.read,fs.write,environment.read --fs-root . --require-ok --json - name: Attach source and Windows native packs without replacement + if: startsWith(github.ref, 'refs/tags/ext-v') shell: bash run: | set -euo pipefail @@ -47,6 +57,7 @@ jobs: needs: windows env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_REF_NAME_OVERRIDE: ${{ startsWith(github.ref, 'refs/tags/') && github.ref_name || format('ext-v{0}', inputs.version || '2.8.1') }} steps: - uses: actions/checkout@v4 with: @@ -63,6 +74,7 @@ jobs: cargo build --release -p marqdo -p marqdo_plugin_agent -p marqdo_plugin_quantum -p marqdo_plugin_linalg -p marqdo_plugin_llm -p marqdo_plugin_engineering bash scripts/build-web-plugin.sh - name: Build and validate the runner's exact pack bytes - run: target/release/marqdo call skills/marqdo-release/packs.mq.md ci --effects plugin,fs.read,fs.write,environment.read --fs-root . --require-ok --json + run: GITHUB_REF_NAME="$GITHUB_REF_NAME_OVERRIDE" target/release/marqdo call skills/marqdo-release/packs.mq.md ci --effects plugin,fs.read,fs.write,environment.read --fs-root . --require-ok --json - name: Attach Linux native pack without replacement + if: startsWith(github.ref, 'refs/tags/ext-v') run: target/release/marqdo call skills/marqdo-release/packs.mq.md attach_ci --effects plugin,fs.read,environment.read --fs-root . --require-ok --json diff --git a/skills/marqdo-release/packs.mq.md b/skills/marqdo-release/packs.mq.md index 0a2c67b..a4aff3d 100755 --- a/skills/marqdo-release/packs.mq.md +++ b/skills/marqdo-release/packs.mq.md @@ -15,7 +15,7 @@ import: This leaf builds source and one platform's native extension archives for an authorized version. It does not publish, choose a version, create a tag or edit version files. The extension-release workflow runs the same tasks on Windows and Linux after local.tag pushes ext-vX.Y.Z. Its attach_ci task creates the exact tagged release through the native service boundary and attaches three assets with the existing gh upload tool; assets.publish subsequently verifies those exact bytes before R2 publication. -Build all six maintained native plugins first. The native_dir contract is a directory containing their platform library names, normally target/release. Source discovery and staging use native Marqdo filesystem operations. Only ZIP encoding uses the existing platform tool: Info-ZIP on Linux, the installed bsdtar on Windows. Compiler and format boundaries do not require Python or a generated shell program. +Build all six maintained native plugins first. The native_dir contract is a directory containing their platform library names, normally target/release. Source discovery and staging use native Marqdo filesystem operations. Only ZIP encoding uses the existing platform tool: Info-ZIP on Linux, 7-Zip on Windows. Compiler and format boundaries do not require Python or a generated shell program. ## libraries @@ -74,7 +74,7 @@ Return *[Reject an unsupported native target](result.error(code="packs.platform" Use `stage`, `entry`, `output` and `platform` only after build preflight. Native resolution validates the stage and output paths first; the encoder receives individual arguments and one named staging subtree. It cannot expand a generated shell expression. A failed encoder can leave the selected incomplete archive for inspection; this task never reuses it as successful output or deletes unrelated files. -The Windows runner supplies bsdtar with ZIP format support; Linux supplies Info-ZIP. Format encoding is the only external operation here. Reads, directory creation, copies, hashes and final ZIP validation remain separate explicit native tasks. The caller removes only its owned temporary stage after the child exits. Existing archives require inspection or a different output directory, keeping reruns from silently replacing publication candidates. +The Windows runner supplies 7-Zip with ZIP format support; Linux supplies Info-ZIP. Format encoding is the only external operation here. Reads, directory creation, copies, hashes and final ZIP validation remain separate explicit native tasks. The caller removes only its owned temporary stage after the child exits. Existing archives require inspection or a different output directory, keeping reruns from silently replacing publication candidates. 1. [This output already belongs to an earlier attempt](fs.exists(path=`output`)) Return *[Preserve the existing archive](result.error(code="packs.output_exists", message=`output`, operation="_archive"))*. @@ -96,9 +96,9 @@ We **destination = [Resolve the new archive inside the granted root](fs.resolve( | argument | |---| - | "C:\\Windows\\System32\\tar.exe" | - | "--format=zip" | - | "-cf" | + | "C:\\Program Files\\7-Zip\\7z.exe" | + | a | + | "-tzip" | | `destination` | | `entry` |