Skip to content

🔧 fix: correctly bundle presets #104

🔧 fix: correctly bundle presets

🔧 fix: correctly bundle presets #104

Workflow file for this run

# Simple workflow for deploying static content to GitHub Pages
name: Deploy JSON and Update
on:
# Runs on pushes targeting the default branch, when certain files are modified
push:
branches: [main]
paths:
- src/config.ts
- src/presets.ts
- src/presets/default.jsonc
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: pages
cancel-in-progress: false
jobs:
# Single deploy job since we're just deploying
deploy:
if: github.actor != 'eemoji-bot'
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
token: ${{ secrets.BOT_PAT }}
- name: Install pnpm
uses: pnpm/action-setup@v2
- name: Set node
uses: actions/setup-node@v3
with:
node-version: 18.x
cache: pnpm
- name: Install
run: pnpm i --ignore-scripts
- name: Build eemoji
run: pnpm run build
- name: Setup eemoji
run: pnpm run postinstall
- name: Generate Schema
run: pnpm run gen:schema
- name: Generate Markdown table
run: pnpm run gen:table
- name: Setup Pages
uses: actions/configure-pages@v3
- name: Upload artifact
uses: actions/upload-pages-artifact@v2
with:
# only upload the eemoji-config-schema.json file
path: json # the json folder
- name: Push changes
run: |
git config --local user.email "eemoji-bot@users.noreply.github.com"
git config --local user.name "eemoji-bot"
git diff --quiet && git diff --staged --quiet || (git commit -a -m "chore: update emojis" && git push)
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2