Allow number inputs to contain empty strings. #156
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: Format code using Prettier | |
on: [push, pull_request] | |
jobs: | |
format: | |
name: Format | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v3 | |
- name: Generate token | |
uses: tibdex/github-app-token@v1 | |
id: generate-token | |
if: github.repository_owner == 'ScratchAddons' | |
continue-on-error: true | |
with: | |
app_id: ${{ secrets.BOT_APP_ID }} | |
private_key: ${{ secrets.BOT_PRIVATE_KEY }} | |
- name: Prettify code (ScratchAddons) | |
if: steps.generate-token.outcome == 'success' | |
uses: ScratchAddons/prettier_action@master | |
with: | |
prettier_options: --write . | |
commit_message: Format code | |
env: | |
GITHUB_TOKEN: ${{ steps.generate-token.outputs.token }} | |
- name: Prettify code (outside ScratchAddons) | |
if: steps.generate-token.outcome != 'success' | |
uses: ScratchAddons/prettier_action@master | |
with: | |
prettier_options: --write . | |
commit_message: Format code | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |