Skip to content

Commit 6b7b48f

Browse files
comment preview deployment url on PR
1 parent 8dc3ebb commit 6b7b48f

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

.github/workflows/deploy_preview.yml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,12 @@ jobs:
3737
run: vercel build --token=${{ secrets.VERCEL_TOKEN }}
3838

3939
- name: Deploy Project Artifacts to Vercel
40-
run: vercel deploy --prebuilt --archive=tgz --token=${{ secrets.VERCEL_TOKEN }}
40+
id: deploy_step
41+
run: echo "preview-url=$(vercel deploy --prebuilt --archive=tgz --token=${{ secrets.VERCEL_TOKEN }})" >>" $GITHUB_OUTPUT
42+
43+
- name: Comment Preview URL
44+
uses: thollander/actions-comment-pull-request@v3
45+
with:
46+
message: |
47+
Preview: ${{ steps.deploy_step.outputs.preview-url }}
48+
comment-tag: preview_url

0 commit comments

Comments
 (0)