Skip to content

Commit

Permalink
Switch to prettier for formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
lilleyse committed Aug 2, 2021
1 parent 829cc3d commit 31470da
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "cesium/node",
"extends": ["cesium/node", "prettier"],
"rules": {
"no-unused-vars": ["error", {"args": "none"}]
}
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ package-lock.json
.idea/workspace.xml
.idea/tasks.xml

# VS Code user-specific
# VSCode user-specific
.vscode

# Generate data
Expand Down
3 changes: 2 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/.vscode
/.idea
/dist
/coverage
Expand All @@ -12,9 +13,9 @@
.gitattributes
.nyc_output
.npmignore
.prettierignore
.travis.yml
.appveyor.yml
gulpfile.js
*.tgz
!doc/gltf.png
.vscode
11 changes: 11 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Ignore everything
*

# Unignore directories (to all depths) and unignore code in these directories
!bin/**/
!doc/**/
!lib/**/
!specs/**/

!**/*.js
!**/*.md
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ node_js:

script:
- npm run eslint
- npm run prettier-check
- npm run test -- --failTaskOnError --suppressPassed;

after_success:
Expand Down
16 changes: 14 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,23 @@
"cloc": "^2.8.0",
"coveralls": "^3.1.1",
"dependency-tree": "^8.1.1",
"eslint": "^7.31.0",
"eslint": "^7.32.0",
"eslint-config-cesium": "^8.0.1",
"eslint-config-prettier": "^8.3.0",
"gulp": "^4.0.2",
"husky": "^4.3.8",
"jasmine": "^3.8.0",
"jasmine-spec-reporter": "^7.0.0",
"jsdoc": "^3.6.7",
"nyc": "^15.1.0",
"open": "^8.2.1"
"open": "^8.2.1",
"prettier": "2.3.2",
"pretty-quick": "^3.1.1"
},
"husky": {
"hooks": {
"pre-commit": "eslint && pretty-quick --staged"
}
},
"scripts": {
"jsdoc": "jsdoc ./lib -R ./README.md -d doc",
Expand All @@ -56,6 +65,9 @@
"coverage": "gulp coverage",
"coveralls": "cat ./coverage/lcov.info | ./node_modules/.bin/coveralls",
"cloc": "gulp cloc",
"prettier": "prettier --write \"**/*\"",
"prettier-check": "prettier --check \"**/*\"",
"pretty-quick": "pretty-quick",
"build-cesium": "gulp build-cesium"
},
"bin": {
Expand Down

0 comments on commit 31470da

Please sign in to comment.