Skip to content

Commit

Permalink
Merge pull request lichess-org#16267 from isaacl/eslintCache
Browse files Browse the repository at this point in the history
Speed up eslint with --cache
  • Loading branch information
schlawg authored Oct 24, 2024
2 parents ea81eb7 + 3591c91 commit 116f9a0
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,6 @@ RUNNING_PID
# Docker-compose / docker sbt
/docker-compose.yml
/?

# eslint cache
/.eslintcache
2 changes: 1 addition & 1 deletion eslint.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import typescriptEslint from '@typescript-eslint/eslint-plugin';
import tsParser from '@typescript-eslint/parser';

export default [
{ ignores: ['*', '!ui/', '!bin/', '**/dist/'] },
{
files: ['**/*.ts'],
ignores: ['**/dist/**', '**/node_modules/**', '**/public/**'],
plugins: { '@typescript-eslint': typescriptEslint },
languageOptions: { parser: tsParser, ecmaVersion: 5, sourceType: 'module' },
rules: {
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,12 +41,12 @@
"typescript": "^5.6.2"
},
"scripts": {
"format": "prettier --write --log-level warn .",
"check-format": "prettier --check --log-level warn .",
"watch-format": "onchange \"**/*\" -- prettier --write --log-level warn {{changed}}",
"format": "prettier --cache --write --log-level warn .",
"check-format": "prettier --cache --check --log-level warn .",
"watch-format": "onchange \"**/*\" -- prettier --cache --write --log-level warn {{changed}}",
"add-hooks": "git config --add core.hooksPath bin/git-hooks",
"remove-hooks": "git config --unset core.hooksPath bin/git-hooks",
"lint": "eslint ui",
"lint": "eslint --cache",
"journal": "journalctl --user -fu lila -o cat",
"metals": "tail -F .metals/metals.log | stdbuf -oL cut -c 21- | rg -v '(notification for request|handleCancellation)'",
"serverlog": "pnpm journal & pnpm metals",
Expand Down

0 comments on commit 116f9a0

Please sign in to comment.