Skip to content

Build CI

Build CI #10

Workflow file for this run

name: Build CI
on:
workflow_dispatch:
branches_ignore:
- "dependabot/**"
concurrency: ${{ github.workflow }}-${{ github.ref }}
jobs:
Build:
runs-on: ubuntu-latest
steps:
# https://github.com/LouisBrunner/checks-action/issues/22#issuecomment-885047551
- name: Recognize sha ref
id: sharef
run: |
if [ "$EVENT" == 'pull_request' ]
then
echo "::set-output name=sha::$(echo ${{github.event.pull_request.head.sha}})"
elif [ "$EVENT" == 'workflow_run' ]
then
echo "::set-output name=sha::$(echo ${{github.event.workflow_run.head_sha}})"
elif [ "$EVENT" == 'workflow_dispatch' ]
then
echo "::set-output name=sha::$(echo ${{github.event.workflow_dispatch.head_sha}})"
else
echo "::set-output name=sha::$(echo $GITHUB_SHA)"
fi
env:
EVENT: ${{ github.event_name }}
REF: ${{ github.ref }}
- name: Checkout repository
uses: actions/checkout@v4
- name: Deploy (Vercel)
uses: amondnet/vercel-action@v25
with:
vercel-token: ${{ secrets.VERCEL_TOKEN }}
vercel-org-id: ${{ secrets.VERCEL_ORG_ID}}
vercel-project-id: ${{ secrets.VERCEL_PROJECT_ID}}
github-comment: false
- name: Add status check
uses: LouisBrunner/[email protected]
if: always()
with:
token: ${{ github.token }}
sha: ${{ steps.sharef.outputs.sha }}
name: Build Check
conclusion: ${{ job.status }}