Adicionado o arquivo .prettierrc com a configuração do Prettier #99
Workflow file for this run
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: Prettier | |
on: | |
pull_request: | |
branches: | |
- main | |
# paths: | |
# - "**/*.{css,html,js,json,liquid,md,scss,yaml,yml}" | |
push: | |
branches: | |
- main | |
# paths: | |
# - "**/*.{css,html,js,json,liquid,md,scss,yaml,yml}" | |
jobs: | |
format: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4.2.2 | |
# with: | |
# ref: ${{ github.head_ref }} | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
- name: Install Prettier | |
run: npm install --save-dev --save-exact prettier @shopify/prettier-plugin-liquid | |
- name: Prettify code | |
run: npx prettier . --write **/*.{css,html,js,json,liquid,md,scss,yaml,yml} | |
# commit all changed files back to the repository | |
- uses: stefanzweifel/git-auto-commit-action@v5.0.1 | |
if: steps.changed-data.outputs.any_changed == 'true' | |
with: | |
commit_message: Prettiy code |