Skip to content

Commit

Permalink
Cleanup base files
Browse files Browse the repository at this point in the history
  • Loading branch information
remal committed Mar 2, 2021
1 parent c99e0a5 commit f2acaab
Show file tree
Hide file tree
Showing 9 changed files with 33 additions and 52 deletions.
9 changes: 4 additions & 5 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
build/
dist/
node_modules/
/*.js
/*.ts
*

!src/
!src/**
3 changes: 1 addition & 2 deletions .eslintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@
],
"parser": "@typescript-eslint/parser",
"parserOptions": {
"ecmaVersion": 9,
"sourceType": "module",
"ecmaVersion": 2019,
"project": "./tsconfig.json"
},
"env": {
Expand Down
18 changes: 6 additions & 12 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,22 +1,16 @@
log/
*.log
hs_err_pid*
java_pid*.hprof

# Maven:
target/

# Gradle:
build/
build-cache/
.gradle/
/build

# NodeJS
/node_modules

# Jest
/coverage

log/
*.log
hs_err_pid*
java_pid*.hprof

# Intellij
/.idea/*
!/.idea/.editorconfig
Expand Down
25 changes: 7 additions & 18 deletions dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
module.exports = {
clearMocks: true,
moduleFileExtensions: ['js', 'ts'],
moduleFileExtensions: ['ts', 'js', 'mjs'],
testEnvironment: 'node',
testRunner: 'jest-circus/runner',
transform: {
'^.+\\.ts$': 'ts-jest'
},
testMatch: [
'**/*.spec.js',
'**/*.spec.ts',
'**/*.spec.(ts|js|mjs)',
],
testPathIgnorePatterns: [
'/node_modules/',
'/build/',
'/dist/',
'/node_modules/',
],
collectCoverage: true,
collectCoverageFrom: [
'src/**',
],
errorOnDeprecated: true,
verbose: true
}
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
},
"main": "dist/main.js",
"scripts": {
"tsconfig-generate-app": "node tsconfig-generate-app",
"lint": "npm run tsconfig-generate-app && eslint --fix src/**/*.[jt]s",
"lint": "eslint --fix",
"test": "jest --passWithNoTests",
"compile": "npm run lint && rimraf build && tsc --rootDir src --outDir build",
"tsconfig-generate-app": "node tsconfig-generate-app",
"compile": "npm run lint && rimraf build && node tsconfig-generate-app && tsc -project tsconfig.app.json --rootDir src --outDir build",
"dist": "npm run compile && rimraf dist && ncc build build/main.js --out dist",
"build": "npm run dist && npm run test"
},
Expand All @@ -22,6 +22,7 @@
"@octokit/plugin-throttling": "3.4.1"
},
"devDependencies": {
"@tsconfig/node12": "1.0.7",
"@types/jest": "26.0.20",
"@types/node": "14.14.31",
"@typescript-eslint/eslint-plugin": "4.16.1",
Expand Down
4 changes: 1 addition & 3 deletions tsconfig.app.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"$schema": "https://json.schemastore.org/tsconfig",
"extends": "@tsconfig/node12/tsconfig.json",
"compilerOptions": {
"target": "ES6",
"module": "CommonJS",
"alwaysStrict": true,
"strict": true,
"strictNullChecks": true,
Expand All @@ -17,7 +16,6 @@
"src/**/*.ts"
],
"exclude": [
"node_modules",
"**/*.spec.*"
]
}
6 changes: 1 addition & 5 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
{
"$schema": "https://json.schemastore.org/tsconfig",
"extends": "@tsconfig/node12/tsconfig.json",
"compilerOptions": {
"target": "ES6",
"module": "CommonJS",
"alwaysStrict": true,
"strict": true,
"strictNullChecks": true,
Expand All @@ -16,8 +15,5 @@
},
"include": [
"src/**/*.ts"
],
"exclude": [
"node_modules"
]
}
5 changes: 5 additions & 0 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -675,6 +675,11 @@
dependencies:
"@sinonjs/commons" "^1.7.0"

"@tsconfig/[email protected]":
version "1.0.7"
resolved "https://registry.yarnpkg.com/@tsconfig/node12/-/node12-1.0.7.tgz#677bd9117e8164dc319987dd6ff5fc1ba6fbf18b"
integrity sha512-dgasobK/Y0wVMswcipr3k0HpevxFJLijN03A8mYfEPvWvOs14v0ZlYTR4kIgMx8g4+fTyTFv8/jLCIfRqLDJ4A==

"@types/babel__core@^7.0.0", "@types/babel__core@^7.1.7":
version "7.1.12"
resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.1.12.tgz#4d8e9e51eb265552a7e4f1ff2219ab6133bdfb2d"
Expand Down

0 comments on commit f2acaab

Please sign in to comment.