Skip to content

inv-153: 참여여부 투표 / 에디터에서 투표 결과 확인 테이블 #218

inv-153: 참여여부 투표 / 에디터에서 투표 결과 확인 테이블

inv-153: 참여여부 투표 / 에디터에서 투표 결과 확인 테이블 #218

Workflow file for this run

name: Vercel Preview Deployment
env:
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
on:
pull_request:
types: [opened, synchronize, reopened]
jobs:
Deploy-Preview:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- name: Install Vercel CLI
run: bun install --global vercel@latest
- name: Pull Vercel Environment Information
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }}
- name: Build Project Artifacts
run: vercel build --token=${{ secrets.VERCEL_TOKEN }}
- name: Deploy Project Artifacts to Vercel
id: deploy
run: |
output=$(vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }})
echo "::set-output name=url::$(echo "$output" | grep -oP 'https://.*\.vercel\.app')"
- name: Get Project Name
id: project-name
run: echo "name=$(echo ${{ github.repository }} | cut -d'/' -f2)" >> $GITHUB_OUTPUT
- name: Format date to Korean time
id: date
run: |
echo "korean_time=$(TZ='Asia/Seoul' date +'%Y-%m-%d %H:%M:%S')" >> $GITHUB_OUTPUT
- name: Find Comment
uses: peter-evans/find-comment@v2
id: fc
with:
issue-number: ${{ github.event.pull_request.number }}
comment-author: "github-actions[bot]"
body-includes: "The latest updates on your projects"
- name: Create or Update Comment
uses: peter-evans/create-or-update-comment@v4
with:
comment-id: ${{ steps.fc.outputs.comment-id }}
issue-number: ${{ github.event.pull_request.number }}
body: |
**The latest updates on your projects**.
| Name | Status | Preview | Updated (UTC) |
| ---- | ------ | ------- | ------------- |
| **${{ steps.project-name.outputs.name }}** | ✅ Ready ([Inspect](https://vercel.com/dashboard)) | [Visit Preview](${{ steps.deploy.outputs.url }}) | ${{ steps.date.outputs.korean_time }} |
edit-mode: replace