From 7a6d07e038813b4e8334a3138008ebc00e0f57f0 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 09:56:06 -0500 Subject: [PATCH 01/16] chore: temporarily comment out npm and github release --- .github/workflows/manual-release.yml | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 08d34aad..0b9e8127 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -81,19 +81,19 @@ jobs: - run: npm run test:e2e # NPM Release (always runs, respects dry-run) - - name: Create NPM release - run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} - env: - NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} + # - name: Create NPM release + # run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} + # env: + # NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} # GitHub Release (only if not dry-run) - - name: Create Release - if: ${{ !inputs.dry-run }} - uses: ./.github/actions/create-release - with: - version: ${{ needs.check.outputs.version }} - channel: ${{ inputs.channel }} - github-token: ${{ secrets.GITHUB_TOKEN }} + # - name: Create Release + # if: ${{ !inputs.dry-run }} + # uses: ./.github/actions/create-release + # with: + # version: ${{ needs.check.outputs.version }} + # channel: ${{ inputs.channel }} + # github-token: ${{ secrets.GITHUB_TOKEN }} # S3 Binary Distribution (only if not dry-run) - name: Download CLI artifacts From f76ef18ce1a0116f1bd5234a1ec39b42114a11ea Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:02:44 -0500 Subject: [PATCH 02/16] chore: add target to oclif upload command --- .github/actions/s3-distribution/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/s3-distribution/action.yml b/.github/actions/s3-distribution/action.yml index 4662d71b..157b9e16 100644 --- a/.github/actions/s3-distribution/action.yml +++ b/.github/actions/s3-distribution/action.yml @@ -70,7 +70,7 @@ runs: ls -la "${{ inputs.artifacts-path }}" echo "Uploading tarballs to S3..." - npx oclif upload tarballs --root=${{ inputs.artifacts-path }} + npx oclif upload tarballs --root=${{ inputs.artifacts-path }} --targets=linux-x64,win32-x64,darwin-arm64 echo "Verifying uploaded files in S3:" aws s3 ls s3://${{ inputs.bucket }}/versions/${{ inputs.version }}/ From 4df95d3d67405f16a799e7ba68a86f9c87e0c0e2 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:21:15 -0500 Subject: [PATCH 03/16] chore: point oclif to tarballs directory for s3 --- .github/workflows/manual-release.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 0b9e8127..12c262b0 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -101,7 +101,7 @@ jobs: uses: actions/download-artifact@cc203385981b70ca67e1cc392babf9cc229d5806 # v4.1.9 with: pattern: 'cli-tarballs-*' - path: ${{ github.workspace }}/dist + path: ${{ github.workspace }}/tarballs merge-multiple: true - name: Debug downloaded artifacts @@ -109,9 +109,9 @@ jobs: shell: bash run: | echo "=== Downloaded artifacts ===" - ls -la ${{ github.workspace }}/dist - echo "=== Contents of dist directory ===" - find ${{ github.workspace }}/dist -type f + ls -la ${{ github.workspace }}/tarballs + echo "=== Contents of tarballs directory ===" + find ${{ github.workspace }}/tarballs -type f - name: Distribute binaries to S3 if: ${{ !inputs.dry-run }} @@ -123,4 +123,4 @@ jobs: aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} aws-region: us-east-1 - artifacts-path: ${{ github.workspace }}/dist + artifacts-path: ${{ github.workspace }}/tarballs From fd88b03ba1d421755e87481d07eba9c9f836c905 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:24:43 -0500 Subject: [PATCH 04/16] chore: ensure xz are not uploaded --- .github/actions/s3-distribution/action.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/actions/s3-distribution/action.yml b/.github/actions/s3-distribution/action.yml index 157b9e16..304223c4 100644 --- a/.github/actions/s3-distribution/action.yml +++ b/.github/actions/s3-distribution/action.yml @@ -70,7 +70,7 @@ runs: ls -la "${{ inputs.artifacts-path }}" echo "Uploading tarballs to S3..." - npx oclif upload tarballs --root=${{ inputs.artifacts-path }} --targets=linux-x64,win32-x64,darwin-arm64 + npx oclif upload tarballs --root=${{ inputs.artifacts-path }} --targets=linux-x64,win32-x64,darwin-arm64 --no-xz echo "Verifying uploaded files in S3:" aws s3 ls s3://${{ inputs.bucket }}/versions/${{ inputs.version }}/ From 051b381acb690ec1856ea6ef4f88ef9bc305a167 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:29:29 -0500 Subject: [PATCH 05/16] chore: revert to using dist --- .github/actions/s3-distribution/action.yml | 2 +- .github/workflows/manual-release.yml | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/actions/s3-distribution/action.yml b/.github/actions/s3-distribution/action.yml index 304223c4..308d65b7 100644 --- a/.github/actions/s3-distribution/action.yml +++ b/.github/actions/s3-distribution/action.yml @@ -70,7 +70,7 @@ runs: ls -la "${{ inputs.artifacts-path }}" echo "Uploading tarballs to S3..." - npx oclif upload tarballs --root=${{ inputs.artifacts-path }} --targets=linux-x64,win32-x64,darwin-arm64 --no-xz + npx oclif upload tarballs --targets=linux-x64,win32-x64,darwin-arm64 --no-xz echo "Verifying uploaded files in S3:" aws s3 ls s3://${{ inputs.bucket }}/versions/${{ inputs.version }}/ diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 12c262b0..0b9e8127 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -101,7 +101,7 @@ jobs: uses: actions/download-artifact@cc203385981b70ca67e1cc392babf9cc229d5806 # v4.1.9 with: pattern: 'cli-tarballs-*' - path: ${{ github.workspace }}/tarballs + path: ${{ github.workspace }}/dist merge-multiple: true - name: Debug downloaded artifacts @@ -109,9 +109,9 @@ jobs: shell: bash run: | echo "=== Downloaded artifacts ===" - ls -la ${{ github.workspace }}/tarballs - echo "=== Contents of tarballs directory ===" - find ${{ github.workspace }}/tarballs -type f + ls -la ${{ github.workspace }}/dist + echo "=== Contents of dist directory ===" + find ${{ github.workspace }}/dist -type f - name: Distribute binaries to S3 if: ${{ !inputs.dry-run }} @@ -123,4 +123,4 @@ jobs: aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} aws-region: us-east-1 - artifacts-path: ${{ github.workspace }}/tarballs + artifacts-path: ${{ github.workspace }}/dist From 48f59463654a614c606f7826d4eab99638264bd2 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:37:24 -0500 Subject: [PATCH 06/16] chore: set s3 acl to bucket owner full control --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index e61a2c04..400a6528 100644 --- a/package.json +++ b/package.json @@ -91,7 +91,7 @@ "s3": { "bucket": "end-of-life-dataset-cli-releases", "host": "https://end-of-life-dataset-cli-releases.s3.amazonaws.com", - "acl": "public-read" + "acl": "bucket-owner-full-control" } } }, From 872d8648b4d53518c983c8b779bfb3bdc27aeb4a Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:48:24 -0500 Subject: [PATCH 07/16] chore: add promote targets as well --- .github/actions/s3-distribution/action.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/actions/s3-distribution/action.yml b/.github/actions/s3-distribution/action.yml index 308d65b7..1321e805 100644 --- a/.github/actions/s3-distribution/action.yml +++ b/.github/actions/s3-distribution/action.yml @@ -91,7 +91,8 @@ runs: --channel=${{ inputs.channel }} \ --version=${{ inputs.version }} \ --sha=${{ github.sha }} \ - --indexes + --indexes \ + --targets=linux-x64,win32-x64,darwin-arm64 echo "Verifying channel promotion in S3:" aws s3 ls s3://${{ inputs.bucket }}/channels/${{ inputs.channel }}/ From cc6fdf7700debdf14b209d726350f9fbcc8c4dec Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 10:59:19 -0500 Subject: [PATCH 08/16] chore: allow promotion to w/o buildmanifest --- .github/actions/s3-distribution/action.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/actions/s3-distribution/action.yml b/.github/actions/s3-distribution/action.yml index 1321e805..b1366d94 100644 --- a/.github/actions/s3-distribution/action.yml +++ b/.github/actions/s3-distribution/action.yml @@ -92,7 +92,8 @@ runs: --version=${{ inputs.version }} \ --sha=${{ github.sha }} \ --indexes \ - --targets=linux-x64,win32-x64,darwin-arm64 + --targets=linux-x64,win32-x64,darwin-arm64 \ + --ignore-missing echo "Verifying channel promotion in S3:" aws s3 ls s3://${{ inputs.bucket }}/channels/${{ inputs.channel }}/ From 7f5ce82e55d003a4bf2a6c24358043ee69b5850d Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:26:50 -0500 Subject: [PATCH 09/16] build: simplify manual release workflow --- .github/workflows/manual-release.yml | 127 +++++++++++++-------------- 1 file changed, 63 insertions(+), 64 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 0b9e8127..e20274b5 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -34,38 +34,10 @@ jobs: run: echo "version=$(node -p "require('./package.json').version")" >> $GITHUB_OUTPUT outputs: version: ${{ steps.version.outputs.version }} - build-platform-tarballs: - strategy: - matrix: - include: - - os: windows-2022 - target: x86_64-pc-windows-msvc - code-target: win32-x64 - - os: ubuntu-20.04 - target: x86_64-unknown-linux-gnu - code-target: linux-x64 - - os: macos-14 - target: aarch64-apple-darwin - code-target: darwin-arm64 - name: Build ${{ matrix.code-target }} binaries - runs-on: ${{ matrix.os }} - needs: check - env: - version: ${{ needs.check.outputs.version }} - steps: - - name: Checkout repository - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 - - name: Install Node.js - uses: actions/setup-node@cdca7365b2dadb8aad0a33bc7601856ffabcc48e # v4.3.0 - with: - node-version-file: '.nvmrc' - - name: Build tarballs - uses: ./.github/actions/build-tarballs - with: - code-target: ${{ matrix.code-target }} + release: runs-on: ubuntu-latest - needs: [check, build-platform-tarballs] + needs: check permissions: contents: write id-token: write @@ -75,52 +47,79 @@ jobs: with: node-version-file: '.nvmrc' registry-url: 'https://registry.npmjs.org' + + # Build and test - run: npm ci - run: npm run build - run: npm test - run: npm run test:e2e - # NPM Release (always runs, respects dry-run) - # - name: Create NPM release - # run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} - # env: - # NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} - - # GitHub Release (only if not dry-run) - # - name: Create Release - # if: ${{ !inputs.dry-run }} - # uses: ./.github/actions/create-release - # with: - # version: ${{ needs.check.outputs.version }} - # channel: ${{ inputs.channel }} - # github-token: ${{ secrets.GITHUB_TOKEN }} - - # S3 Binary Distribution (only if not dry-run) - - name: Download CLI artifacts + # Create GitHub Release + - name: Create Release if: ${{ !inputs.dry-run }} - uses: actions/download-artifact@cc203385981b70ca67e1cc392babf9cc229d5806 # v4.1.9 + uses: softprops/action-gh-release@v1 with: - pattern: 'cli-tarballs-*' - path: ${{ github.workspace }}/dist - merge-multiple: true + tag_name: v${{ needs.check.outputs.version }} + name: Release v${{ needs.check.outputs.version }} ${{ inputs.channel == 'latest' && 'Latest' || inputs.channel }} + body: | + ## Changes - - name: Debug downloaded artifacts - if: ${{ !inputs.dry-run }} - shell: bash + This release includes the following platform-specific binaries: + - macOS (ARM64) + - Windows (x64) + - Linux (x64) + draft: false + prerelease: ${{ inputs.channel != 'latest' }} + discussion_category_name: Announcements + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + + # Build platform-specific tarballs + - name: Install linux toolchain run: | - echo "=== Downloaded artifacts ===" - ls -la ${{ github.workspace }}/dist - echo "=== Contents of dist directory ===" - find ${{ github.workspace }}/dist -type f + sudo apt update + sudo apt install nsis p7zip-full p7zip-rar -y + + - name: Build linux-x64 tarball + run: npx oclif pack tarballs --targets=linux-x64 --no-xz + + - name: Build win32-x64 tarball + run: npx oclif pack tarballs --targets=win32-x64 --no-xz - - name: Distribute binaries to S3 + - name: Build darwin-arm64 tarball + run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz + + # S3 Distribution + - name: Configure AWS credentials if: ${{ !inputs.dry-run }} - uses: ./.github/actions/s3-distribution + uses: aws-actions/configure-aws-credentials@v4 with: - version: ${{ needs.check.outputs.version }} - channel: ${{ inputs.channel }} - bucket: end-of-life-dataset-cli-releases aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} aws-region: us-east-1 - artifacts-path: ${{ github.workspace }}/dist + + - name: Upload and promote to S3 + if: ${{ !inputs.dry-run }} + run: | + # Enable oclif debug logging + export DEBUG=oclif:* + + # Upload tarballs + npx oclif upload tarballs \ + --targets=linux-x64,win32-x64,darwin-arm64 \ + --no-xz + + # Promote to channel + npx oclif promote \ + --channel=${{ inputs.channel }} \ + --version=${{ needs.check.outputs.version }} \ + --sha=${{ github.sha }} \ + --indexes \ + --targets=linux-x64,win32-x64,darwin-arm64 \ + --ignore-missing + + # NPM Release + - name: Create NPM release + run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} + env: + NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file From 18cdc5404e7ba28ea8a0b2bd149555d53f1adbb0 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:27:22 -0500 Subject: [PATCH 10/16] chore: comment out npm and github release --- .github/workflows/manual-release.yml | 42 ++++++++++++++-------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index e20274b5..9989c91e 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -55,24 +55,24 @@ jobs: - run: npm run test:e2e # Create GitHub Release - - name: Create Release - if: ${{ !inputs.dry-run }} - uses: softprops/action-gh-release@v1 - with: - tag_name: v${{ needs.check.outputs.version }} - name: Release v${{ needs.check.outputs.version }} ${{ inputs.channel == 'latest' && 'Latest' || inputs.channel }} - body: | - ## Changes + # - name: Create Release + # if: ${{ !inputs.dry-run }} + # uses: softprops/action-gh-release@v1 + # with: + # tag_name: v${{ needs.check.outputs.version }} + # name: Release v${{ needs.check.outputs.version }} ${{ inputs.channel == 'latest' && 'Latest' || inputs.channel }} + # body: | + # ## Changes - This release includes the following platform-specific binaries: - - macOS (ARM64) - - Windows (x64) - - Linux (x64) - draft: false - prerelease: ${{ inputs.channel != 'latest' }} - discussion_category_name: Announcements - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + # This release includes the following platform-specific binaries: + # - macOS (ARM64) + # - Windows (x64) + # - Linux (x64) + # draft: false + # prerelease: ${{ inputs.channel != 'latest' }} + # discussion_category_name: Announcements + # env: + # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Build platform-specific tarballs - name: Install linux toolchain @@ -119,7 +119,7 @@ jobs: --ignore-missing # NPM Release - - name: Create NPM release - run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} - env: - NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file + # - name: Create NPM release + # run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} + # env: + # NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file From bf8787bd0d76b2406b32dee712a84c9b40713c50 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:32:43 -0500 Subject: [PATCH 11/16] chore: test github release --- .github/workflows/manual-release.yml | 106 +++++++++++++-------------- 1 file changed, 53 insertions(+), 53 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 9989c91e..c8593230 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -55,68 +55,68 @@ jobs: - run: npm run test:e2e # Create GitHub Release - # - name: Create Release - # if: ${{ !inputs.dry-run }} - # uses: softprops/action-gh-release@v1 - # with: - # tag_name: v${{ needs.check.outputs.version }} - # name: Release v${{ needs.check.outputs.version }} ${{ inputs.channel == 'latest' && 'Latest' || inputs.channel }} - # body: | - # ## Changes + - name: Create Release + if: ${{ !inputs.dry-run }} + uses: softprops/action-gh-release@v1 + with: + tag_name: v${{ needs.check.outputs.version }} + name: Release v${{ needs.check.outputs.version }} ${{ inputs.channel == 'latest' && 'Latest' || inputs.channel }} + body: | + ## Changes - # This release includes the following platform-specific binaries: - # - macOS (ARM64) - # - Windows (x64) - # - Linux (x64) - # draft: false - # prerelease: ${{ inputs.channel != 'latest' }} - # discussion_category_name: Announcements - # env: - # GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + This release includes the following platform-specific binaries: + - macOS (ARM64) + - Windows (x64) + - Linux (x64) + draft: false + prerelease: ${{ inputs.channel != 'latest' }} + discussion_category_name: Announcements + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # Build platform-specific tarballs - - name: Install linux toolchain - run: | - sudo apt update - sudo apt install nsis p7zip-full p7zip-rar -y + # # Build platform-specific tarballs + # - name: Install linux toolchain + # run: | + # sudo apt update + # sudo apt install nsis p7zip-full p7zip-rar -y - - name: Build linux-x64 tarball - run: npx oclif pack tarballs --targets=linux-x64 --no-xz + # - name: Build linux-x64 tarball + # run: npx oclif pack tarballs --targets=linux-x64 --no-xz - - name: Build win32-x64 tarball - run: npx oclif pack tarballs --targets=win32-x64 --no-xz + # - name: Build win32-x64 tarball + # run: npx oclif pack tarballs --targets=win32-x64 --no-xz - - name: Build darwin-arm64 tarball - run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz + # - name: Build darwin-arm64 tarball + # run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz - # S3 Distribution - - name: Configure AWS credentials - if: ${{ !inputs.dry-run }} - uses: aws-actions/configure-aws-credentials@v4 - with: - aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} - aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} - aws-region: us-east-1 + # # S3 Distribution + # - name: Configure AWS credentials + # if: ${{ !inputs.dry-run }} + # uses: aws-actions/configure-aws-credentials@v4 + # with: + # aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} + # aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + # aws-region: us-east-1 - - name: Upload and promote to S3 - if: ${{ !inputs.dry-run }} - run: | - # Enable oclif debug logging - export DEBUG=oclif:* + # - name: Upload and promote to S3 + # if: ${{ !inputs.dry-run }} + # run: | + # # Enable oclif debug logging + # export DEBUG=oclif:* - # Upload tarballs - npx oclif upload tarballs \ - --targets=linux-x64,win32-x64,darwin-arm64 \ - --no-xz + # # Upload tarballs + # npx oclif upload tarballs \ + # --targets=linux-x64,win32-x64,darwin-arm64 \ + # --no-xz - # Promote to channel - npx oclif promote \ - --channel=${{ inputs.channel }} \ - --version=${{ needs.check.outputs.version }} \ - --sha=${{ github.sha }} \ - --indexes \ - --targets=linux-x64,win32-x64,darwin-arm64 \ - --ignore-missing + # # Promote to channel + # npx oclif promote \ + # --channel=${{ inputs.channel }} \ + # --version=${{ needs.check.outputs.version }} \ + # --sha=${{ github.sha }} \ + # --indexes \ + # --targets=linux-x64,win32-x64,darwin-arm64 \ + # --ignore-missing # NPM Release # - name: Create NPM release From b26bebaa4c3281a400683c0ffc67f4e7e7c9bdcf Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:35:37 -0500 Subject: [PATCH 12/16] chore: uncomment release steps --- .github/workflows/manual-release.yml | 80 ++++++++++++++-------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index c8593230..e20274b5 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -74,52 +74,52 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # # Build platform-specific tarballs - # - name: Install linux toolchain - # run: | - # sudo apt update - # sudo apt install nsis p7zip-full p7zip-rar -y + # Build platform-specific tarballs + - name: Install linux toolchain + run: | + sudo apt update + sudo apt install nsis p7zip-full p7zip-rar -y - # - name: Build linux-x64 tarball - # run: npx oclif pack tarballs --targets=linux-x64 --no-xz + - name: Build linux-x64 tarball + run: npx oclif pack tarballs --targets=linux-x64 --no-xz - # - name: Build win32-x64 tarball - # run: npx oclif pack tarballs --targets=win32-x64 --no-xz + - name: Build win32-x64 tarball + run: npx oclif pack tarballs --targets=win32-x64 --no-xz - # - name: Build darwin-arm64 tarball - # run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz + - name: Build darwin-arm64 tarball + run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz - # # S3 Distribution - # - name: Configure AWS credentials - # if: ${{ !inputs.dry-run }} - # uses: aws-actions/configure-aws-credentials@v4 - # with: - # aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} - # aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} - # aws-region: us-east-1 + # S3 Distribution + - name: Configure AWS credentials + if: ${{ !inputs.dry-run }} + uses: aws-actions/configure-aws-credentials@v4 + with: + aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} + aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} + aws-region: us-east-1 - # - name: Upload and promote to S3 - # if: ${{ !inputs.dry-run }} - # run: | - # # Enable oclif debug logging - # export DEBUG=oclif:* + - name: Upload and promote to S3 + if: ${{ !inputs.dry-run }} + run: | + # Enable oclif debug logging + export DEBUG=oclif:* - # # Upload tarballs - # npx oclif upload tarballs \ - # --targets=linux-x64,win32-x64,darwin-arm64 \ - # --no-xz + # Upload tarballs + npx oclif upload tarballs \ + --targets=linux-x64,win32-x64,darwin-arm64 \ + --no-xz - # # Promote to channel - # npx oclif promote \ - # --channel=${{ inputs.channel }} \ - # --version=${{ needs.check.outputs.version }} \ - # --sha=${{ github.sha }} \ - # --indexes \ - # --targets=linux-x64,win32-x64,darwin-arm64 \ - # --ignore-missing + # Promote to channel + npx oclif promote \ + --channel=${{ inputs.channel }} \ + --version=${{ needs.check.outputs.version }} \ + --sha=${{ github.sha }} \ + --indexes \ + --targets=linux-x64,win32-x64,darwin-arm64 \ + --ignore-missing # NPM Release - # - name: Create NPM release - # run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} - # env: - # NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file + - name: Create NPM release + run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} + env: + NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file From ba2818641d387fba379bb77e9a8a4474abc87f49 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:41:58 -0500 Subject: [PATCH 13/16] chore: upload tarballs to release --- .github/workflows/manual-release.yml | 36 +++++++++++++++------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index e20274b5..2527988b 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -54,7 +54,22 @@ jobs: - run: npm test - run: npm run test:e2e - # Create GitHub Release + # Build platform-specific tarballs + - name: Install linux toolchain + run: | + sudo apt update + sudo apt install nsis p7zip-full p7zip-rar -y + + - name: Build linux-x64 tarball + run: npx oclif pack tarballs --targets=linux-x64 --no-xz + + - name: Build win32-x64 tarball + run: npx oclif pack tarballs --targets=win32-x64 --no-xz + + - name: Build darwin-arm64 tarball + run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz + + # Create GitHub Release with assets - name: Create Release if: ${{ !inputs.dry-run }} uses: softprops/action-gh-release@v1 @@ -71,24 +86,13 @@ jobs: draft: false prerelease: ${{ inputs.channel != 'latest' }} discussion_category_name: Announcements + files: | + dist/hd-*-linux-x64.tar.gz + dist/hd-*-win32-x64.tar.gz + dist/hd-*-darwin-arm64.tar.gz env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # Build platform-specific tarballs - - name: Install linux toolchain - run: | - sudo apt update - sudo apt install nsis p7zip-full p7zip-rar -y - - - name: Build linux-x64 tarball - run: npx oclif pack tarballs --targets=linux-x64 --no-xz - - - name: Build win32-x64 tarball - run: npx oclif pack tarballs --targets=win32-x64 --no-xz - - - name: Build darwin-arm64 tarball - run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz - # S3 Distribution - name: Configure AWS credentials if: ${{ !inputs.dry-run }} From 4429ff154cbade9159e4967e7b40dc0aa0a20df5 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:42:44 -0500 Subject: [PATCH 14/16] chore: temporarily comment out npm release --- .github/workflows/manual-release.yml | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 2527988b..a59e1668 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -122,8 +122,8 @@ jobs: --targets=linux-x64,win32-x64,darwin-arm64 \ --ignore-missing - # NPM Release - - name: Create NPM release - run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} - env: - NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file + # # NPM Release + # - name: Create NPM release + # run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} + # env: + # NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file From 1d6ed780bb4f70553629fff6c922b4ca2667bd87 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:53:34 -0500 Subject: [PATCH 15/16] chore: for now delete github release step --- .github/workflows/manual-release.yml | 32 ++++------------------------ 1 file changed, 4 insertions(+), 28 deletions(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index a59e1668..8efe4548 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -69,30 +69,6 @@ jobs: - name: Build darwin-arm64 tarball run: npx oclif pack tarballs --targets=darwin-arm64 --no-xz - # Create GitHub Release with assets - - name: Create Release - if: ${{ !inputs.dry-run }} - uses: softprops/action-gh-release@v1 - with: - tag_name: v${{ needs.check.outputs.version }} - name: Release v${{ needs.check.outputs.version }} ${{ inputs.channel == 'latest' && 'Latest' || inputs.channel }} - body: | - ## Changes - - This release includes the following platform-specific binaries: - - macOS (ARM64) - - Windows (x64) - - Linux (x64) - draft: false - prerelease: ${{ inputs.channel != 'latest' }} - discussion_category_name: Announcements - files: | - dist/hd-*-linux-x64.tar.gz - dist/hd-*-win32-x64.tar.gz - dist/hd-*-darwin-arm64.tar.gz - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - # S3 Distribution - name: Configure AWS credentials if: ${{ !inputs.dry-run }} @@ -123,7 +99,7 @@ jobs: --ignore-missing # # NPM Release - # - name: Create NPM release - # run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} - # env: - # NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file + - name: Create NPM release + run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} + env: + NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file From 646151e924315e568e58cd1ba7b71991cb408b00 Mon Sep 17 00:00:00 2001 From: Edward Ezekiel Date: Fri, 4 Apr 2025 11:56:30 -0500 Subject: [PATCH 16/16] chore: add missing eof --- .github/workflows/manual-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/manual-release.yml b/.github/workflows/manual-release.yml index 8efe4548..3dd47331 100644 --- a/.github/workflows/manual-release.yml +++ b/.github/workflows/manual-release.yml @@ -102,4 +102,4 @@ jobs: - name: Create NPM release run: npm publish --tag ${{ inputs.channel }} --provenance --access public ${{ inputs.dry-run == true && '--dry-run' || '' }} env: - NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }} \ No newline at end of file + NODE_AUTH_TOKEN: ${{ secrets.HD_CLI_NPM_TOKEN }}