Skip to content

Commit f75724f

Browse files
committed
conf file setup
0 parents  commit f75724f

11 files changed

+434
-0
lines changed

.editorconfig

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# http://editorconfig.org
2+
root = true
3+
4+
[*]
5+
charset = utf-8
6+
end_of_line = lf
7+
indent_size = 4
8+
indent_style = space
9+
insert_final_newline = true
10+
max_line_length = 120
11+
trim_trailing_whitespace = true
12+
13+
[*.md]
14+
max_line_length = 0
15+
trim_trailing_whitespace = false
16+
17+
[COMMIT_EDITMSG]
18+
max_line_length = 0

.eslintignore

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
node_modules/**
2+
packages/**/dist/**
3+
packages/**/node_modules/**
4+
!.eslintrc.js

.eslintrc.json

+286
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,286 @@
1+
{
2+
"root": true,
3+
"env": {
4+
"node": true,
5+
"es6": true
6+
},
7+
"extends": [
8+
"eslint:recommended",
9+
"plugin:@typescript-eslint/recommended",
10+
"prettier/@typescript-eslint",
11+
"plugin:prettier/recommended",
12+
"plugin:jest/recommended"
13+
],
14+
"parser": "@typescript-eslint/parser",
15+
"parserOptions": {
16+
"ecmaVersion": 2018,
17+
"sourceType": "module"
18+
},
19+
"plugins": ["@typescript-eslint/eslint-plugin"],
20+
"overrides": [
21+
{
22+
"files": ["**/*.js"],
23+
"rules": {
24+
"@typescript-eslint/no-var-requires": "off"
25+
}
26+
},
27+
{
28+
"files": ["**/*.ts"],
29+
"rules": {
30+
"@typescript-eslint/no-use-before-define": [
31+
"error",
32+
{
33+
"classes": false,
34+
"functions": false
35+
}
36+
]
37+
}
38+
},
39+
{
40+
"files": ["packages/**/graphql.schema.ts"],
41+
"rules": {
42+
"@typescript-eslint/interface-name-prefix": "off"
43+
}
44+
},
45+
{
46+
"files": ["packages/cli/src/commands/**/*.test.ts", "packages/cli/src/**/*.e2e.ts"],
47+
"rules": {
48+
"jest/no-standalone-expect": ["off"]
49+
}
50+
},
51+
{
52+
"files": ["packages/web/**/*.e2e.ts", "packages/electron/**/*.e2e.ts"],
53+
"rules": {
54+
"jest/expect-expect": ["off"]
55+
}
56+
},
57+
{
58+
"files": ["packages/types/src/**/*.ts"],
59+
"rules": {
60+
"@typescript-eslint/ban-ts-ignore": ["off"]
61+
}
62+
}
63+
],
64+
"rules": {
65+
"@typescript-eslint/interface-name-prefix": ["error", "always"],
66+
"@typescript-eslint/no-unused-vars": ["error", { "args": "none" }],
67+
"array-bracket-spacing": ["error", "never"],
68+
"array-callback-return": "error",
69+
"arrow-body-style": "off",
70+
"arrow-parens": ["error", "always"],
71+
"arrow-spacing": "error",
72+
"block-scoped-var": "error",
73+
"block-spacing": ["error", "always"],
74+
"brace-style": "error",
75+
"camelcase": "error",
76+
"comma-dangle": ["error", "always-multiline"],
77+
"comma-style": ["error", "last"],
78+
"complexity": ["warn", 10],
79+
"computed-property-spacing": "error",
80+
"consistent-return": "error",
81+
"consistent-this": ["error", "self"],
82+
"constructor-super": "error",
83+
"curly": ["error", "all"],
84+
"default-case": "error",
85+
"default-param-last": "warn",
86+
"dot-location": ["error", "property"],
87+
"dot-notation": "error",
88+
"eol-last": "error",
89+
"eqeqeq": "error",
90+
"func-call-spacing": "error",
91+
"func-names": "error",
92+
"func-style": ["error", "declaration", { "allowArrowFunctions": true }],
93+
"function-call-argument-newline": ["error", "consistent"],
94+
"generator-star-spacing": "error",
95+
"grouped-accessor-pairs": "warn",
96+
"indent": ["error", 4, { "SwitchCase": 1 }],
97+
"key-spacing": "error",
98+
"keyword-spacing": "error",
99+
"line-comment-position": "error",
100+
"linebreak-style": "error",
101+
"lines-around-comment": "warn",
102+
"lines-between-class-members": "error",
103+
"max-depth": "error",
104+
"max-len": ["error", { "code": 120, "comments": 120, "ignoreUrls": true }],
105+
"max-lines": ["warn", 500],
106+
"max-lines-per-function": ["warn", 100],
107+
"max-nested-callbacks": ["error", 5],
108+
"max-params": ["warn", 4],
109+
"max-statements": "warn",
110+
"max-statements-per-line": "error",
111+
"new-parens": "error",
112+
"newline-per-chained-call": "error",
113+
"no-alert": "error",
114+
"no-array-constructor": "error",
115+
"no-await-in-loop": "error",
116+
"no-buffer-constructor": "error",
117+
"no-caller": "error",
118+
"no-confusing-arrow": "error",
119+
"no-console": "error",
120+
"no-constructor-return": "error",
121+
"no-constant-condition": "error",
122+
"no-debugger": "error",
123+
"no-dupe-else-if": "error",
124+
"no-duplicate-imports": "error",
125+
"no-else-return": "error",
126+
"no-empty-function": [
127+
"error",
128+
{
129+
"allow": ["constructors"]
130+
}
131+
],
132+
"no-eq-null": "error",
133+
"no-eval": "error",
134+
"no-extend-native": "error",
135+
"no-extra-bind": "error",
136+
"no-extra-label": "error",
137+
"no-floating-decimal": "error",
138+
"no-implicit-coercion": "error",
139+
"no-implicit-globals": "error",
140+
"no-implied-eval": "error",
141+
"no-import-assign": "error",
142+
"no-invalid-this": "off",
143+
"no-iterator": "error",
144+
"no-labels": "error",
145+
"no-lone-blocks": "error",
146+
"no-lonely-if": "error",
147+
"no-loop-func": "error",
148+
"no-magic-numbers": "off",
149+
"no-multi-assign": "error",
150+
"no-multi-spaces": "error",
151+
"no-multi-str": "error",
152+
"no-multiple-empty-lines": "error",
153+
"no-nested-ternary": "error",
154+
"no-new": "error",
155+
"no-new-func": "error",
156+
"no-new-object": "error",
157+
"no-new-wrappers": "error",
158+
"no-octal-escape": "error",
159+
"no-param-reassign": "error",
160+
"no-path-concat": "error",
161+
"no-plusplus": [
162+
"error",
163+
{
164+
"allowForLoopAfterthoughts": true
165+
}
166+
],
167+
"no-proto": "error",
168+
"no-restricted-globals": "error",
169+
"no-restricted-syntax": [
170+
"error",
171+
{
172+
"selector": "NewExpression[callee.name='TestDbmss']",
173+
"message": "Do not use 'new TestDbmss()', use 'TestDbmss.init()' instead."
174+
}
175+
],
176+
"no-restricted-properties": [
177+
"error",
178+
{
179+
"object": "fse",
180+
"property": "rename",
181+
"message": "Use fse.move instead"
182+
},
183+
{
184+
"object": "fs",
185+
"property": "rename",
186+
"message": "Use fse.move instead"
187+
},
188+
{
189+
"object": "flags",
190+
"property": "credentials",
191+
"message": "Use passwordPrompt instead"
192+
},
193+
{
194+
"object": "flags",
195+
"property": "password",
196+
"message": "Use passwordPrompt instead"
197+
}
198+
],
199+
"no-return-assign": "error",
200+
"no-return-await": "error",
201+
"no-self-compare": "error",
202+
"no-sequences": "error",
203+
"no-setter-return": "error",
204+
"no-shadow": "error",
205+
"no-sync": "error",
206+
"no-tabs": "error",
207+
"no-template-curly-in-string": "error",
208+
"no-trailing-spaces": "error",
209+
"no-underscore-dangle": "error",
210+
"no-unmodified-loop-condition": "error",
211+
"no-unneeded-ternary": "error",
212+
"no-unreachable": "error",
213+
"no-unused-expressions": "error",
214+
"no-use-before-define": [
215+
"error",
216+
{
217+
"classes": false,
218+
"functions": false
219+
}
220+
],
221+
"no-useless-call": "error",
222+
"no-useless-computed-key": "error",
223+
"no-useless-concat": "error",
224+
"no-useless-rename": "error",
225+
"no-useless-return": "error",
226+
"no-var": "error",
227+
"no-void": "error",
228+
"no-whitespace-before-property": "error",
229+
"object-curly-newline": "error",
230+
"object-curly-spacing": "error",
231+
"object-property-newline": "error",
232+
"one-var": ["error", "never"],
233+
"one-var-declaration-per-line": ["error", "always"],
234+
"operator-assignment": "error",
235+
"operator-linebreak": "error",
236+
"padded-blocks": ["error", "never"],
237+
"padding-line-between-statements": "error",
238+
"prefer-arrow-callback": "error",
239+
"prefer-const": "error",
240+
"prefer-destructuring": [
241+
"error",
242+
{
243+
"VariableDeclarator": {
244+
"array": true,
245+
"object": true
246+
},
247+
"AssignmentExpression": {
248+
"array": false,
249+
"object": false
250+
}
251+
}
252+
],
253+
"prefer-numeric-literals": "error",
254+
"prefer-promise-reject-errors": "error",
255+
"prefer-rest-params": "error",
256+
"prefer-spread": "error",
257+
"prefer-template": "error",
258+
"radix": "error",
259+
"require-atomic-updates": "warn",
260+
"require-await": "error",
261+
"rest-spread-spacing": "error",
262+
"semi": "error",
263+
"semi-spacing": "error",
264+
"semi-style": "error",
265+
"sort-keys": "off",
266+
"space-before-blocks": "error",
267+
"space-before-function-paren": [
268+
"error",
269+
{
270+
"anonymous": "always",
271+
"asyncArrow": "always",
272+
"named": "never"
273+
}
274+
],
275+
"space-in-parens": "error",
276+
"space-infix-ops": "error",
277+
"space-unary-ops": "error",
278+
"spaced-comment": "error",
279+
"switch-colon-spacing": "error",
280+
"symbol-description": "error",
281+
"template-curly-spacing": "error",
282+
"template-tag-spacing": "error",
283+
"yield-star-spacing": "error",
284+
"yoda": "error"
285+
}
286+
}

.gitignore

+76
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
lerna-debug.log*
6+
yarn-error.log*
7+
8+
# Runtime data
9+
pids
10+
*.pid
11+
*.seed
12+
*.pid.lock
13+
14+
# Directory for instrumented libs generated by jscoverage/JSCover
15+
lib-cov
16+
17+
# Coverage directory used by tools like istanbul
18+
coverage
19+
20+
# nyc test coverage
21+
.nyc_output
22+
23+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
24+
.grunt
25+
26+
# Bower dependency directory (https://bower.io/)
27+
bower_components
28+
29+
# node-waf configuration
30+
.lock-wscript
31+
32+
# Compiled binary addons (https://nodejs.org/api/addons.html)
33+
build/Release
34+
35+
# Dependency directories
36+
node_modules/
37+
jspm_packages/
38+
39+
# Build directories
40+
dist/
41+
tmp/
42+
43+
# Optional npm cache directory
44+
.npm
45+
46+
# Optional eslint cache
47+
.eslintcache
48+
49+
# Optional REPL history
50+
.node_repl_history
51+
52+
# Output of 'npm pack'
53+
*.tgz
54+
55+
# Yarn Integrity file
56+
.yarn-integrity
57+
58+
# dotenv environment variables file
59+
.env
60+
61+
# next.js build output
62+
.next
63+
64+
# IDEA
65+
.idea
66+
.vscode
67+
68+
# OSX
69+
.DS_Store
70+
71+
# Oclif generated file
72+
oclif.manifest.json
73+
74+
# E2E generated dirs
75+
e2e/fixtures/data/
76+
e2e/fixtures/cache/

.huskyrc

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"hooks": {
3+
"pre-commit": "lint-staged",
4+
"pre-push": "npm test"
5+
}
6+
}

0 commit comments

Comments
 (0)