Skip to content

Commit

Permalink
ci: Add action for automatically running Prettier (#3727)
Browse files Browse the repository at this point in the history
* ci: Add action for automatically running Prettier

This patch sets up a GitHub Action for automatically running Prettier. Now that #3725 has landed, automatically running Prettier shouldn't [generate too much noise](#3631 (comment)).

This will prevent needing to spend time opening PRs just for running Prettier, and enables us to remove some of the Grunt code for doing so.

* an unpretty change

* Prettified Code!

Co-authored-by: stephenmathieson <stephenmathieson@users.noreply.github.com>
  • Loading branch information
stephenmathieson and stephenmathieson committed Oct 27, 2022
1 parent 32c27a6 commit 213ad5c
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions .github/workflows/format.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Formatter

on: [pull_request]

jobs:
prettier:
runs-on: ubuntu-latest
steps:
- name: Cloning the repository
uses: actions/checkout@v3
with:
ref: ${{ github.head_ref }}
fetch-depth: 0
- name: Prettify the code
uses: creyD/prettier_action@v4.2
with:
prettier_options: '--write .'

0 comments on commit 213ad5c

Please sign in to comment.