Skip to content

Commit

Permalink
Tancik/prettier on merge (nerfstudio-project#138)
Browse files Browse the repository at this point in the history
* Add prettier formatting to github action
  • Loading branch information
tancik authored Jul 14, 2022
1 parent c5eecae commit 2230b7d
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 1 deletion.
25 changes: 25 additions & 0 deletions .github/workflows/prettier.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Prettier

on:
pull_request:
branches:
- master
types: [closed]

jobs:
prettier:
if: ${{ github.event.pull_request.merged }}
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
# Make sure the actual branch is checked out when running on pull requests
ref: ${{ github.head_ref }}

- name: Prettify JS code
uses: creyD/[email protected]
with:
# This part is also where you can pass other options, for example:
prettier_options: --write ./pyrad/**/*.js
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -178,4 +178,7 @@ temp*
.nfs*
external/
__MACOSX/
outputs*/
outputs*/
node_modules/
yarn.lock
package.json

0 comments on commit 2230b7d

Please sign in to comment.