Skip to content

Build assets

Build assets #1522

name: Style Prettier
on: [push]
jobs:
style:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [ 19.x ]
steps:
- uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Install node packages
run: npm ci
- name: Extract branch name
shell: bash
run: echo "##[set-output name=branch;]$(echo ${GITHUB_REF#refs/heads/})"
id: extract_branch
- name: Run fixer
run: npm run prettier
- uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Apply prettier changes
push_options: '--force'
branch: ${{ steps.extract_branch.outputs.branch }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}