Skip to content

Commit c112d45

Browse files
committed
fix: streamline Vercel deployment steps by removing redundant URL extraction
1 parent 736d4d9 commit c112d45

File tree

1 file changed

+2
-24
lines changed

1 file changed

+2
-24
lines changed

Diff for: .github/workflows/vercel-preview.yml

+2-24
Original file line numberDiff line numberDiff line change
@@ -2,44 +2,22 @@ name: Vercel Preview Deployment
22
env:
33
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
44
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
5-
65
on:
76
push:
87
branches-ignore:
98
- main
10-
119
jobs:
1210
Deploy-Preview:
1311
runs-on: ubuntu-20.04
1412
environment:
15-
name: preview # Environment is linked here
16-
13+
name: preview
1714
steps:
1815
- uses: actions/checkout@v4
19-
2016
- name: Install Vercel CLI
2117
run: npm install --global vercel@latest
22-
2318
- name: Pull Vercel Environment Information
2419
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
25-
2620
- name: Build Project Artifacts
2721
run: vercel build --token=${{ secrets.VERCEL_TOKEN }}
28-
2922
- name: Deploy Project Artifacts to Vercel
30-
run: |
31-
vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }} > deployment.txt
32-
id: deploy
33-
34-
- name: Extract Deployment URL
35-
run: |
36-
DEPLOYMENT_URL=$(tail -n 1 deployment.txt)
37-
echo "DEPLOYMENT_URL=$DEPLOYMENT_URL" >> $GITHUB_ENV
38-
id: extract-url
39-
40-
# Step to set URL for the deployment manually
41-
- name: Update Environment URL
42-
if: success()
43-
run: echo "::set-output name=environment_url::${{ env.DEPLOYMENT_URL }}"
44-
env:
45-
DEPLOYMENT_URL: "https://google.com"
23+
run: vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }}

0 commit comments

Comments
 (0)