Skip to content
This repository was archived by the owner on Nov 20, 2025. It is now read-only.

Commit 3337fbf

Browse files
introduce github action for docs
1 parent 732c296 commit 3337fbf

File tree

2 files changed

+48
-0
lines changed

2 files changed

+48
-0
lines changed

.github/workflows/preview.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: GitHub Actions Vercel Preview Deployment
2+
env:
3+
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
4+
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
5+
on:
6+
push:
7+
branches:
8+
- canary
9+
paths:
10+
- docs/**
11+
12+
jobs:
13+
Deploy-Preview:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v2
17+
- name: Install Vercel CLI
18+
run: npm install --global vercel@canary
19+
- name: Pull Vercel Environment Information
20+
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
21+
- name: Build Project Artifacts
22+
run: vercel build --token=${{ secrets.VERCEL_TOKEN }}
23+
- name: Deploy Project Artifacts to Vercel
24+
run: vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }}

.github/workflows/production.yaml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: GitHub Actions Vercel Production Deployment
2+
env:
3+
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
4+
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
5+
on:
6+
push:
7+
branches:
8+
- main
9+
paths:
10+
- docs/**
11+
jobs:
12+
Deploy-Production:
13+
if: github.repository == 'frontendweb3/section-blog-theme'
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: actions/checkout@v2
17+
- name: Install Vercel CLI
18+
run: npm install --global vercel@canary
19+
- name: Pull Vercel Environment Information
20+
run: vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
21+
- name: Build Project Artifacts
22+
run: vercel build --prod --token=${{ secrets.VERCEL_TOKEN }}
23+
- name: Deploy Project Artifacts to Vercel
24+
run: vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }}

0 commit comments

Comments
 (0)