Skip to content

feat: add PR tarball workflow with direct download link#576

Merged
aidandaly24 merged 4 commits intomainfrom
feat/pr-tarball-workflow
Mar 19, 2026
Merged

feat: add PR tarball workflow with direct download link#576
aidandaly24 merged 4 commits intomainfrom
feat/pr-tarball-workflow

Conversation

@jesseturner21
Copy link
Contributor

Description

Adds an automated tarball workflow to the existing build-and-test.yml CI pipeline. On every PR:

  1. After the build succeeds (Node 20.x), npm pack creates a .tgz tarball
  2. The tarball is uploaded as a GitHub Release asset (pre-release tagged pr-<number>-tarball)
  3. A sticky comment is posted on the PR with a direct download link and a one-liner npm install command
  4. When the PR is closed or merged, the temporary release and tag are automatically cleaned up

This allows reviewers and testers to easily try out changes from any PR without cloning the branch — just copy the npm install <url> command from the PR comment.

What changed in build-and-test.yml

  • Added closed to pull_request event types (needed for cleanup)
  • Added if: github.event.action != 'closed' guard on the build and coverage jobs so they don't run on PR close
  • Added npm pack + upload-artifact steps to the build matrix (Node 20.x only)
  • Added pr-tarball job: downloads artifact, creates a GitHub pre-release with the tarball, posts sticky PR comment
  • Added cleanup-pr-tarball job: deletes the temporary release/tag when the PR is closed

Tested on

Verified end-to-end on jesseturner21/tarball-workflow-test#1 — build, release creation, PR comment with direct download link, and npm install <url> all work correctly.

Related Issue

N/A — workflow improvement

Documentation PR

N/A

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update
  • Other (please describe):

Testing

How have you tested the change?

  • I ran npm run test:unit and npm run test:integ
  • I ran npm run typecheck
  • I ran npm run lint
  • If I modified src/assets/, I ran npm run test:update-snapshots and committed the updated snapshots

Workflow tested end-to-end on a test repo: jesseturner21/tarball-workflow-test#1

Checklist

  • I have read the CONTRIBUTING document
  • I have added any necessary tests that prove my fix is effective or my feature works
  • I have updated the documentation accordingly
  • I have added an appropriate example to the documentation to outline the feature, or no new docs are needed
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the
terms of your choice.

On every PR, the build workflow now also runs `npm pack` and uploads
the resulting tarball as a GitHub Release asset. A sticky comment is
posted on the PR with a direct download link and a one-liner npm
install command. The temporary release is automatically cleaned up
when the PR is closed or merged.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@jesseturner21 jesseturner21 requested a review from a team March 19, 2026 21:41
@github-actions github-actions bot added the size/s PR size: S label Mar 19, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 19, 2026

Coverage Report

Status Category Percentage Covered / Total
🔵 Lines 43.06% 4899 / 11376
🔵 Statements 42.67% 5189 / 12160
🔵 Functions 42.43% 900 / 2121
🔵 Branches 44.49% 3163 / 7108
Generated in workflow #1051 for commit b0c472e by the Vitest Coverage Report Action

@github-actions
Copy link
Contributor

Package Tarball

aws-agentcore-0.3.0-preview.6.0.tgz

How to install

npm install https://github.com/aws/agentcore-cli/releases/download/pr-576-tarball/aws-agentcore-0.3.0-preview.6.0.tgz

Removes the cleanup-pr-tarball job so tarball releases persist after
PR close. This allows testing packages from old/closed PRs.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions github-actions bot added size/s PR size: S and removed size/s PR size: S labels Mar 19, 2026
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions github-actions bot added size/s PR size: S and removed size/s PR size: S labels Mar 19, 2026
Runs daily at midnight UTC. Deletes PR tarball releases (and their
tags) older than 7 days. Can also be triggered manually.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions github-actions bot added size/s PR size: S and removed size/s PR size: S labels Mar 19, 2026
Copy link
Contributor

@Hweinstock Hweinstock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice!

@aidandaly24 aidandaly24 merged commit c0aeaae into main Mar 19, 2026
20 of 21 checks passed
@aidandaly24 aidandaly24 deleted the feat/pr-tarball-workflow branch March 19, 2026 22:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size/s PR size: S

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants