-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Uses Prettier (https://prettier.io/) to find style issues in the code. It runs on every commit to the main branch and every pull request using GitHub Actions (https://github.com/features/actions).
- Loading branch information
1 parent
9610984
commit a5483ab
Showing
8 changed files
with
147 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
name: CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- 'main' | ||
pull_request: | ||
|
||
permissions: | ||
contents: read | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | ||
|
||
jobs: | ||
format: | ||
name: 'Format' | ||
runs-on: ubuntu-22.04 | ||
timeout-minutes: 30 | ||
|
||
steps: | ||
- name: 'Checkout code' | ||
uses: actions/[email protected] | ||
|
||
- name: 'Set up Node.js' | ||
uses: actions/[email protected] | ||
with: | ||
node-version-file: package.json | ||
cache: ${{ !env.ACT && 'npm' || '' }} | ||
|
||
- name: 'Install dependencies' | ||
run: npm ci | ||
|
||
- name: 'Run formatter' | ||
run: npx prettier --ignore-unknown --check '**' |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/node_modules/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
audit = false | ||
engine-strict = true | ||
fund = false |
Empty file.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"arrowParens": "avoid", | ||
"printWidth": 120, | ||
"semi": false, | ||
"singleQuote": true, | ||
"plugins": ["prettier-plugin-sh"] | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
.PHONY: fix format | ||
|
||
node_modules: package.json package-lock.json | ||
npm install | ||
touch node_modules | ||
|
||
fix: node_modules | ||
npx prettier --ignore-unknown --write '**' | ||
|
||
format: node_modules | ||
npx prettier --ignore-unknown --check '**' |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"private": true, | ||
"engines": { | ||
"node": "20", | ||
"npm": "9 || 10" | ||
}, | ||
"devDependencies": { | ||
"prettier": "^3.1.0", | ||
"prettier-plugin-sh": "^0.13.1" | ||
} | ||
} |