Skip to content

Commit

Permalink
Move jest, eslint & prettier to the root (gravitational#20698)
Browse files Browse the repository at this point in the history
* Move jest, eslint & prettier to the root

* Update e ref
  • Loading branch information
ryanclark authored Jan 25, 2023
1 parent 08e3f75 commit 27ad839
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 12 deletions.
File renamed without changes.
2 changes: 1 addition & 1 deletion e
Submodule e updated from 60f60b to 58d97c
File renamed without changes.
9 changes: 4 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
"package-term": "yarn workspace @gravitational/namespaces package-term",
"build-native-deps-for-term": "yarn workspace @gravitational/namespaces build-native-deps-for-term",
"build-and-package-term-ci": "yarn workspace @gravitational/namespaces build-and-package-term-ci",
"test": "yarn workspace @gravitational/namespaces test",
"test": "jest",
"lint": "yarn prettier-check && yarn eslint",
"eslint": "eslint --quiet --ext .js,.jsx,.ts,.tsx web/",
"eslint": "eslint --quiet --ext .js,.jsx,.ts,.tsx web/ e/",
"type-check": "tsc --noEmit",
"prettier-check": "yarn prettier --check 'web/**/*.{ts,tsx,js,jsx,md}'",
"prettier-write": "yarn prettier --write 'web/**/*.{ts,tsx,js,jsx,md}'"
"prettier-check": "yarn prettier --check '+(e|web)/**/*.{ts,tsx,js,jsx,md}'",
"prettier-write": "yarn prettier --write '+(e|web)/**/*.{ts,tsx,js,jsx,md}'"
},
"private": true,
"resolutions": {
Expand All @@ -37,5 +37,4 @@
"e/web/**"
]
}

}
12 changes: 6 additions & 6 deletions web/packages/build/jest/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ module.exports = {
// mock all imports to asset files
'\\.(css|scss|stylesheet)$': path.join(__dirname, 'mockStyles.js'),
'\\.(png|svg|yaml|yaml\\?raw)$': path.join(__dirname, 'mockFiles.js'),
'^shared/(.*)$': '<rootDir>/packages/shared/$1',
'^design($|/.*)': '<rootDir>/packages/design/src/$1',
'^teleport($|/.*)': '<rootDir>/packages/teleport/src/$1',
'^teleterm($|/.*)': '<rootDir>/packages/teleterm/src/$1',
'^e-teleport/(.*)$': '<rootDir>/../e/web/teleport/src/$1',
'^e-teleterm/(.*)$': '<rootDir>/../e/web/teleterm/src/$1',
'^shared/(.*)$': '<rootDir>/web/packages/shared/$1',
'^design($|/.*)': '<rootDir>/web/packages/design/src/$1',
'^teleport($|/.*)': '<rootDir>/web/packages/teleport/src/$1',
'^teleterm($|/.*)': '<rootDir>/web/packages/teleterm/src/$1',
'^e-teleport/(.*)$': '<rootDir>/e/web/teleport/src/$1',
'^e-teleterm/(.*)$': '<rootDir>/e/web/teleterm/src/$1',
},
};

0 comments on commit 27ad839

Please sign in to comment.