Skip to content

Commit

Permalink
fix: eslint + ios android build number
Browse files Browse the repository at this point in the history
  • Loading branch information
riderx committed Sep 6, 2022
1 parent f829ccc commit 5e4e339
Show file tree
Hide file tree
Showing 10 changed files with 1,282 additions and 1,756 deletions.
53 changes: 0 additions & 53 deletions .eslintrc

This file was deleted.

113 changes: 113 additions & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,113 @@
module.exports = {
root: true,
overrides: [
{
files: ['*.ts'],
parser: '@typescript-eslint/parser',
parserOptions: {
project: ['tsconfig.eslint.json'],
createDefaultProgram: true,
},
plugins: ['prettier', 'simple-import-sort'],
extends: [
'plugin:import/recommended',
'plugin:import/typescript',
'airbnb-typescript/base',
'prettier',
'plugin:prettier/recommended',
],
rules: {
'prettier/prettier': 'error',
'simple-import-sort/imports': [
'error',
{
groups: [
// Side effect imports.
['^\\u0000'],
// Parent imports. Put `..` last.
['^\\.\\.(?!/?$)', '^\\.\\./?$'],
// Other relative imports. Put same-folder imports and `.` last.
['^\\./(?=.*/)(?!/?$)', '^\\.(?!/?$)', '^\\./?$'],
// Style imports.
['^.+\\.s?css$'],
],
},
],
'simple-import-sort/exports': 'error',
'import/first': 'error',
'import/newline-after-import': 'error',
'import/no-duplicates': 'error',
'max-len': [
'error',
{
code: 100,
ignorePattern: '^import .*',
ignoreComments: true,
ignoreUrls: true,
ignoreStrings: true,
ignoreTemplateLiterals: true,
ignoreRegExpLiterals: true,
},
],
'@typescript-eslint/lines-between-class-members': [
'error',
'always',
{ exceptAfterSingleLine: true },
],
'@typescript-eslint/naming-convention': [
'error',
{
selector: 'interface',
format: ['PascalCase'],
custom: {
regex: '^I[A-Z]',
match: true,
},
},
{
selector: 'typeAlias',
format: ['PascalCase'],
custom: {
regex: '^T[A-Z]',
match: true,
},
},
{
selector: 'enum',
format: ['PascalCase'],
custom: {
regex: '^E[A-Z]',
match: true,
},
},
],
},
reportUnusedDisableDirectives: true,
},
{
files: ['*.interface.ts', '*.enum.ts', '*.model.ts'],
parser: '@typescript-eslint/parser',
parserOptions: {
extraFileExtensions: ['*.ts'],
project: ['tsconfig.eslint.json'],
createDefaultProgram: true,
},
plugins: ['prettier'],
extends: ['plugin:typescript-sort-keys/recommended'],
},
{
files: ['src/**/*.spec.ts', 'src/**/*.d.ts', 'src/**/*.mock.ts'],
parserOptions: {
project: ['tsconfig.eslint.json'],
createDefaultProgram: true,
},
plugins: ['prettier', 'jasmine'],
extends: ['plugin:jasmine/recommended'],
env: { jasmine: true },
rules: {
'@typescript-eslint/no-unused-vars': 'off',
'jasmine/no-disabled-tests': 'off',
},
},
],
};
13 changes: 13 additions & 0 deletions .prettierrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{
"arrowParens": "avoid",
"trailingComma": "es5",
"tabWidth": 2,
"semi": true,
"singleQuote": true,
"printWidth": 100,
"attributeSort": "ASC",
"attributeGroups": [
"$DEFAULT",
"^data-"
]
}
2 changes: 1 addition & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"editor.formatOnSave": true,
"editor.formatOnSave": false,
"javascript.format.enable": false
}
26 changes: 16 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "capacitor-standard-version",
"version": "1.0.12",
"version": "1.0.13",
"description": "Default standard-version config for capacitor app",
"main": "dist/index.js",
"bin": {
Expand Down Expand Up @@ -36,20 +36,26 @@
"devDependencies": {
"@types/adm-zip": "^0.4.34",
"@types/fs-extra": "^9.0.13",
"@typescript-eslint/eslint-plugin": "5.14.0",
"@typescript-eslint/parser": "^5.14.0",
"awesome-typescript-loader": "^5.2.1",
"eslint": "^8.11.0",
"eslint-config-airbnb-base": "^15.0.0",
"@types/node": "^18.7.15",
"@typescript-eslint/eslint-plugin": "^5.36.1",
"@typescript-eslint/parser": "^5.36.1",
"eslint": "^8.23.0",
"eslint-config-airbnb-typescript": "^17.0.0",
"eslint-config-prettier": "^8.5.0",
"eslint-import-resolver-typescript": "^2.5.0",
"eslint-plugin-import": "^2.25.4",
"eslint-plugin-prettier": "^4.0.0",
"eslint-plugin-import": "^2.26.0",
"eslint-plugin-jasmine": "^4.1.3",
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-simple-import-sort": "^7.0.0",
"eslint-plugin-typescript-sort-keys": "^2.1.0",
"git-format-staged": "^2.1.3",
"husky": "^7.0.4",
"nodemon": "^2.0.15",
"pkg": "^5.5.2",
"prettier": "^2.5.1",
"prettier": "^2.7.1",
"prettier-eslint": "^15.0.1",
"prettier-eslint-cli": "^7.1.0",
"prettier-plugin-organize-attributes": "^0.0.5",
"ts-loader": "^9.3.1",
"ts-node": "^10.7.0",
"tsconfig-paths": "^3.14.0",
"typescript": "^4.6.2",
Expand Down

0 comments on commit 5e4e339

Please sign in to comment.