Created
September 15, 2022 13:27
-
-
Save diego3g/015f3a286eca02f284c9095bfa0c2e4a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Generate design tokens | |
on: | |
repository_dispatch: | |
types: update-tokens | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Create input JSON | |
id: create-json | |
uses: jsdaniell/[email protected] | |
with: | |
name: ${{ github.event.client_payload.filename }} | |
json: ${{ github.event.client_payload.tokens }} | |
dir: 'input' | |
- name: Install Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- name: Install dependencies | |
run: npm ci | |
- name: Build | |
run: npm run build | |
- name: Create PR | |
uses: peter-evans/create-pull-request@v4 | |
with: | |
commit-message: "style: Update design tokens" | |
title: ${{ github.event.client_payload.commitMessage || 'Update design tokens' }} | |
body: "Design tokens have been updated via Figma and need to be reviewed." | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
BRANCH_NAME: 'main' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment