Skip to content

Commit

Permalink
Merge pull request #1336 from pixiv/lint-staged-examples
Browse files Browse the repository at this point in the history
chore: use lint-staged also for examples directories
  • Loading branch information
0b5vr authored Dec 4, 2023
2 parents c41f4f5 + 9636b96 commit e84c516
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 12 deletions.
7 changes: 5 additions & 2 deletions packages/three-vrm-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,16 @@
"docs": "typedoc --entryPoints ./src/index.ts --out docs",
"test": "jest",
"lint": "eslint \"src/**/*.{ts,tsx}\" && yarn lint-examples && prettier \"src/**/*.{ts,tsx}\" --check",
"lint-examples": "eslint \"examples/**/*.{ts,tsx,js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{ts,tsx,js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
"lint-examples": "eslint \"examples/**/*.{js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
},
"lint-staged": {
"./src/**/*.{ts,tsx}": [
"eslint --fix",
"prettier --write"
],
"./examples/**/*.{js,html}": [
"eslint --fix --rule \"padded-blocks: error\""
]
},
"dependencies": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,16 @@
"build-types": "tsc --declaration --declarationDir ./types --emitDeclarationOnly && downlevel-dts types ts3.4/types",
"docs": "typedoc --entryPoints ./src/index.ts --out docs",
"lint": "eslint \"src/**/*.{ts,tsx}\" && yarn lint-examples && prettier \"src/**/*.{ts,tsx}\" --check",
"lint-examples": "eslint \"examples/**/*.{ts,tsx,js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{ts,tsx,js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
"lint-examples": "eslint \"examples/**/*.{js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
},
"lint-staged": {
"./src/**/*.{ts,tsx}": [
"eslint --fix",
"prettier --write"
],
"./examples/**/*.{js,html}": [
"eslint --fix --rule \"padded-blocks: error\""
]
},
"dependencies": {
Expand Down
7 changes: 5 additions & 2 deletions packages/three-vrm-materials-mtoon/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,16 @@
"build-types": "tsc --declaration --declarationDir ./types --emitDeclarationOnly && downlevel-dts types ts3.4/types",
"docs": "typedoc --entryPoints ./src/index.ts --out docs",
"lint": "eslint \"src/**/*.{ts,tsx}\" && yarn lint-examples && prettier \"src/**/*.{ts,tsx}\" --check",
"lint-examples": "eslint \"examples/**/*.{ts,tsx,js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{ts,tsx,js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
"lint-examples": "eslint \"examples/**/*.{js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
},
"lint-staged": {
"./src/**/*.{ts,tsx}": [
"eslint --fix",
"prettier --write"
],
"./examples/**/*.{js,html}": [
"eslint --fix --rule \"padded-blocks: error\""
]
},
"dependencies": {
Expand Down
7 changes: 5 additions & 2 deletions packages/three-vrm-node-constraint/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,16 @@
"docs": "typedoc --entryPoints ./src/index.ts --out docs",
"test": "jest",
"lint": "eslint \"src/**/*.{ts,tsx}\" && yarn lint-examples && prettier \"src/**/*.{ts,tsx}\" --check",
"lint-examples": "eslint \"examples/**/*.{ts,tsx,js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{ts,tsx,js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
"lint-examples": "eslint \"examples/**/*.{js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
},
"lint-staged": {
"./src/**/*.{ts,tsx}": [
"eslint --fix",
"prettier --write"
],
"./examples/**/*.{js,html}": [
"eslint --fix --rule \"padded-blocks: error\""
]
},
"dependencies": {
Expand Down
7 changes: 5 additions & 2 deletions packages/three-vrm-springbone/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,16 @@
"docs": "typedoc --entryPoints ./src/index.ts --out docs",
"test": "jest",
"lint": "eslint \"src/**/*.{ts,tsx}\" && yarn lint-examples && prettier \"src/**/*.{ts,tsx}\" --check",
"lint-examples": "eslint \"examples/**/*.{ts,tsx,js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{ts,tsx,js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
"lint-examples": "eslint \"examples/**/*.{js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
},
"lint-staged": {
"./src/**/*.{ts,tsx}": [
"eslint --fix",
"prettier --write"
],
"./examples/**/*.{js,html}": [
"eslint --fix --rule \"padded-blocks: error\""
]
},
"dependencies": {
Expand Down
7 changes: 5 additions & 2 deletions packages/three-vrm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,16 @@
"docs": "typedoc --entryPoints ./src/index.ts --out docs",
"test": "echo There is no test for three-vrm",
"lint": "eslint \"src/**/*.{ts,tsx}\" && yarn lint-examples && prettier \"src/**/*.{ts,tsx}\" --check",
"lint-examples": "eslint \"examples/**/*.{ts,tsx,js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{ts,tsx,js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
"lint-examples": "eslint \"examples/**/*.{js,html}\" --rule \"padded-blocks: error\"",
"lint-fix": "eslint \"src/**/*.{ts,tsx}\" --fix && eslint \"examples/**/*.{js,html}\" --fix && prettier \"src/**/*.{ts,tsx}\" --write"
},
"lint-staged": {
"./src/**/*.{ts,tsx}": [
"eslint --fix",
"prettier --write"
],
"./examples/**/*.{js,html}": [
"eslint --fix --rule \"padded-blocks: error\""
]
},
"dependencies": {
Expand Down

0 comments on commit e84c516

Please sign in to comment.