Skip to content

Commit 7f138d1

Browse files
Merge branch 'main' into fix/batch-trigger-task-identifier
2 parents 31ecd33 + 3c0644a commit 7f138d1

File tree

384 files changed

+36075
-5415
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

384 files changed

+36075
-5415
lines changed

.changeset/add-debounce-maxdelay.md

Lines changed: 0 additions & 16 deletions
This file was deleted.

.changeset/calm-hooks-wait.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

.changeset/consistent-stream-targets.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

.changeset/export-start-attempt-hook-type.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

.changeset/fix-dead-process-execute-hang.md

Lines changed: 0 additions & 5 deletions
This file was deleted.

.changeset/vendor-superjson-esm-fix.md

Lines changed: 0 additions & 7 deletions
This file was deleted.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Vouch Request
2+
description: Request to be vouched as a contributor
3+
labels: ["vouch-request"]
4+
body:
5+
- type: markdown
6+
attributes:
7+
value: |
8+
## Vouch Request
9+
10+
We use [vouch](https://github.com/mitchellh/vouch) to manage contributor trust. PRs from unvouched users are automatically closed.
11+
12+
To get vouched, fill out this form. A maintainer will review your request and vouch for you by commenting on this issue.
13+
- type: textarea
14+
id: context
15+
attributes:
16+
label: Why do you want to contribute?
17+
description: Tell us a bit about yourself and what you'd like to work on.
18+
placeholder: "I'd like to fix a bug I found in..."
19+
validations:
20+
required: true
21+
- type: textarea
22+
id: prior-work
23+
attributes:
24+
label: Prior contributions or relevant experience
25+
description: Links to previous open source work, relevant projects, or anything that helps us understand your background.
26+
placeholder: "https://github.com/..."
27+
validations:
28+
required: false

.github/VOUCHED.td

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Vouched contributors for Trigger.dev
2+
# See: https://github.com/mitchellh/vouch
3+
#
4+
# Org members
5+
0ski
6+
D-K-P
7+
ericallam
8+
matt-aitken
9+
mpcgrid
10+
myftija
11+
nicktrn
12+
samejr
13+
isshaddad
14+
# Outside contributors
15+
gautamsi
16+
capaj

.github/workflows/changesets-pr.yml

Lines changed: 30 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ on:
77
paths:
88
- "packages/**"
99
- ".changeset/**"
10+
- ".server-changes/**"
1011
- "package.json"
1112
- "pnpm-lock.yaml"
1213

@@ -50,7 +51,7 @@ jobs:
5051
env:
5152
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5253

53-
- name: Update PR title with version
54+
- name: Update PR title and enhance body
5455
if: steps.changesets.outputs.published != 'true'
5556
env:
5657
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -61,6 +62,15 @@ jobs:
6162
# we arbitrarily reference the version of the cli package here; it is the same for all package releases
6263
VERSION=$(git show origin/changeset-release/main:packages/cli-v3/package.json | jq -r '.version')
6364
gh pr edit "$PR_NUMBER" --title "chore: release v$VERSION"
65+
66+
# Enhance the PR body with a clean, deduplicated summary
67+
RAW_BODY=$(gh pr view "$PR_NUMBER" --json body --jq '.body')
68+
ENHANCED_BODY=$(CHANGESET_PR_BODY="$RAW_BODY" node scripts/enhance-release-pr.mjs "$VERSION")
69+
if [ -n "$ENHANCED_BODY" ]; then
70+
gh api repos/triggerdotdev/trigger.dev/pulls/"$PR_NUMBER" \
71+
-X PATCH \
72+
-f body="$ENHANCED_BODY"
73+
fi
6474
fi
6575
6676
update-lockfile:
@@ -88,15 +98,26 @@ jobs:
8898
- name: Install and update lockfile
8999
run: pnpm install --no-frozen-lockfile
90100

91-
- name: Commit and push lockfile
101+
- name: Clean up consumed .server-changes/ files
92102
run: |
93103
set -e
94-
if git diff --quiet pnpm-lock.yaml; then
95-
echo "No lockfile changes"
96-
else
97-
git config user.name "github-actions[bot]"
98-
git config user.email "github-actions[bot]@users.noreply.github.com"
99-
git add pnpm-lock.yaml
100-
git commit -m "chore: update lockfile for release"
104+
shopt -s nullglob
105+
files=(.server-changes/*.md)
106+
for f in "${files[@]}"; do
107+
if [ "$(basename "$f")" != "README.md" ]; then
108+
git rm --ignore-unmatch "$f"
109+
fi
110+
done
111+
112+
- name: Commit and push lockfile + server-changes cleanup
113+
run: |
114+
set -e
115+
git config user.name "github-actions[bot]"
116+
git config user.email "github-actions[bot]@users.noreply.github.com"
117+
git add pnpm-lock.yaml
118+
if ! git diff --cached --quiet; then
119+
git commit -m "chore: update lockfile and clean up .server-changes/ for release"
101120
git push origin changeset-release/main
121+
else
122+
echo "No changes to commit"
102123
fi

.github/workflows/release.yml

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ jobs:
111111
uses: changesets/action@v1
112112
with:
113113
publish: pnpm run changeset:release
114-
createGithubReleases: true
114+
createGithubReleases: false
115115
env:
116116
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
117117

@@ -122,6 +122,19 @@ jobs:
122122
package_version=$(echo '${{ steps.changesets.outputs.publishedPackages }}' | jq -r '.[0].version')
123123
echo "package_version=${package_version}" >> "$GITHUB_OUTPUT"
124124
125+
- name: Create unified GitHub release
126+
if: steps.changesets.outputs.published == 'true'
127+
env:
128+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
129+
RELEASE_PR_BODY: ${{ github.event.pull_request.body }}
130+
run: |
131+
VERSION="${{ steps.get_version.outputs.package_version }}"
132+
node scripts/generate-github-release.mjs "$VERSION" > /tmp/release-body.md
133+
gh release create "v${VERSION}" \
134+
--title "trigger.dev v${VERSION}" \
135+
--notes-file /tmp/release-body.md \
136+
--target main
137+
125138
- name: Create and push Docker tag
126139
if: steps.changesets.outputs.published == 'true'
127140
run: |
@@ -140,6 +153,47 @@ jobs:
140153
with:
141154
image_tag: v${{ needs.release.outputs.published_package_version }}
142155

156+
# After Docker images are published, update the GitHub release with the exact GHCR tag URL.
157+
# The GHCR package version ID is only known after the image is pushed, so we query for it here.
158+
update-release:
159+
name: 🔗 Update release Docker link
160+
needs: [release, publish-docker]
161+
if: needs.release.outputs.published == 'true'
162+
runs-on: ubuntu-latest
163+
permissions:
164+
contents: write
165+
packages: read
166+
steps:
167+
- name: Update GitHub release with Docker image link
168+
env:
169+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
170+
run: |
171+
set -e
172+
VERSION="${{ needs.release.outputs.published_package_version }}"
173+
TAG="v${VERSION}"
174+
175+
# Query GHCR for the version ID matching this tag
176+
VERSION_ID=$(gh api --paginate -H "Accept: application/vnd.github+json" \
177+
/orgs/triggerdotdev/packages/container/trigger.dev/versions \
178+
--jq ".[] | select(.metadata.container.tags[] == \"${TAG}\") | .id" \
179+
| head -1)
180+
181+
if [ -z "$VERSION_ID" ]; then
182+
echo "Warning: Could not find GHCR version ID for tag ${TAG}, skipping update"
183+
exit 0
184+
fi
185+
186+
DOCKER_URL="https://github.com/triggerdotdev/trigger.dev/pkgs/container/trigger.dev/${VERSION_ID}?tag=${TAG}"
187+
GENERIC_URL="https://github.com/triggerdotdev/trigger.dev/pkgs/container/trigger.dev"
188+
189+
# Get current release body and replace the generic link with the tag-specific one.
190+
# Use word boundary after GENERIC_URL (closing paren) to avoid matching URLs that
191+
# already have a version ID appended (idempotent on re-runs).
192+
gh release view "${TAG}" --json body --jq '.body' > /tmp/release-body.md
193+
sed -i "s|${GENERIC_URL})|${DOCKER_URL})|g" /tmp/release-body.md
194+
195+
gh release edit "${TAG}" --notes-file /tmp/release-body.md
196+
143197
# The prerelease job needs to be on the same workflow file due to a limitation related to how npm verifies OIDC claims.
144198
prerelease:
145199
name: 🧪 Prerelease

0 commit comments

Comments
 (0)