Skip to content

アップデート #185

アップデート

アップデート #185

Workflow file for this run

name: GitHub Pages Deploy
# Controls when the workflow will run
on:
push:
branches: ["develop"]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: "20"
- uses: pnpm/action-setup@v2
with:
version: 8
- run: pnpm install
- run: pnpm run build
- name: Prepare static files
run: |
mkdir _site/
cp dist/sora.js _site/
cp example/check.html _site/
cp example/sw.js _site/
- name: Upload files
uses: actions/upload-pages-artifact@v2
- name: Slack Notification
if: failure()
uses: rtCamp/action-slack-notify@v2
env:
SLACK_CHANNEL: sora-js-sdk
SLACK_COLOR: danger
SLACK_TITLE: Failure test
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
deploy:
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2