Skip to content
This repository was archived by the owner on Jan 19, 2019. It is now read-only.
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 8d79499

Browse files
authoredOct 24, 2018
Merge branch 'master' into add-visitor-keys
2 parents 75f1020 + 4172933 commit 8d79499

File tree

11 files changed

+49
-40
lines changed

11 files changed

+49
-40
lines changed
 

‎.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,4 @@ _test.js
66
.DS_Store
77
.vscode
88
yarn.lock
9+
.eslint-release-info.json

‎CHANGELOG.md

+9
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
v20.0.0 - October 8, 2018
2+
3+
* f4b9893 Breaking: Support TypeScript 3.1 (fixes #524) (#525) (James Henry)
4+
5+
v19.0.2 - September 29, 2018
6+
7+
* aa0fe13 Fix: Re-expose parse method (fixes #519) (#521) (Kevin Partington)
8+
* 655359f Chore: Makefile tweaks (#522) (Kevin Partington)
9+
110
v19.0.1 - September 25, 2018
211

312
* 7a367c7 Fix: Remove lib from package.json files (#518) (James Henry)

‎Makefile.js

+17-21
Original file line numberDiff line numberDiff line change
@@ -26,23 +26,6 @@ const OPEN_SOURCE_LICENSES = [
2626
/MIT/, /BSD/, /Apache/, /ISC/, /WTF/, /Public Domain/
2727
];
2828

29-
//------------------------------------------------------------------------------
30-
// Data
31-
//------------------------------------------------------------------------------
32-
33-
const NODE_MODULES = "./node_modules/",
34-
35-
// Utilities - intentional extra space at the end of each string
36-
JEST = `${NODE_MODULES}jest/bin/jest.js`,
37-
38-
// Files
39-
MAKEFILE = "./Makefile.js",
40-
/* eslint-disable no-use-before-define */
41-
JS_FILES = "parser.js visitor-keys.js",
42-
TEST_FILES = find("tests/lib/").filter(fileType("js")).join(" "),
43-
TOOLS_FILES = find("tools/").filter(fileType("js")).join(" ");
44-
/* eslint-enable no-use-before-define */
45-
4629
//------------------------------------------------------------------------------
4730
// Helpers
4831
//------------------------------------------------------------------------------
@@ -59,6 +42,19 @@ function fileType(extension) {
5942
};
6043
}
6144

45+
//------------------------------------------------------------------------------
46+
// Data
47+
//------------------------------------------------------------------------------
48+
49+
const JEST = "jest",
50+
LINT_OPTIONS = "--report-unused-disable-directives",
51+
52+
// Files
53+
MAKEFILE = "./Makefile.js",
54+
JS_FILES = "parser.js visitor-keys.js",
55+
TEST_FILES = find("tests/lib/").filter(fileType("js")).join(" "),
56+
TOOLS_FILES = find("tools/").filter(fileType("js")).join(" ");
57+
6258
//------------------------------------------------------------------------------
6359
// Tasks
6460
//------------------------------------------------------------------------------
@@ -72,25 +68,25 @@ target.lint = function() {
7268
lastReturn;
7369

7470
echo("Validating Makefile.js");
75-
lastReturn = nodeCLI.exec("eslint", MAKEFILE);
71+
lastReturn = nodeCLI.exec("eslint", MAKEFILE, LINT_OPTIONS);
7672
if (lastReturn.code !== 0) {
7773
errors++;
7874
}
7975

8076
echo("Validating JavaScript files");
81-
lastReturn = nodeCLI.exec("eslint", JS_FILES);
77+
lastReturn = nodeCLI.exec("eslint", JS_FILES, LINT_OPTIONS);
8278
if (lastReturn.code !== 0) {
8379
errors++;
8480
}
8581

8682
echo("Validating JavaScript test files");
87-
lastReturn = nodeCLI.exec("eslint", TEST_FILES);
83+
lastReturn = nodeCLI.exec("eslint", TEST_FILES, LINT_OPTIONS);
8884
if (lastReturn.code !== 0) {
8985
errors++;
9086
}
9187

9288
echo("Validating JavaScript tools files");
93-
lastReturn = nodeCLI.exec("eslint", TOOLS_FILES);
89+
lastReturn = nodeCLI.exec("eslint", TOOLS_FILES, LINT_OPTIONS);
9490
if (lastReturn.code !== 0) {
9591
errors++;
9692
}

‎README.md

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
> <h1>Help Wanted!</h1>
2+
> If you're familiar with TypeScript and ESLint, and you'd like to see this project progress, please consider contributing. We need people with a good knowledge of TypeScript to ensure that the integration with the ESLint ecosystem is useful.
3+
14
# TypeScript ESLint Parser
25

36
An ESLint custom parser which leverages [TypeScript ESTree](https://github.com/JamesHenry/typescript-estree) to allow for ESLint to lint TypeScript source code.
@@ -37,10 +40,6 @@ If you use a non-supported version of TypeScript, the parser will log a warning
3740

3841
**Please ensure that you are using a supported version before submitting any issues/bug reports.**
3942

40-
## Help Wanted!
41-
42-
If you're familiar with TypeScript and ESLint, and you'd like to see this project progress, please consider contributing. We need people with a good knowledge of TypeScript to ensure this parser is useful.
43-
4443
## Reporting Issues
4544

4645
Please **do not report parsing/AST issues in this repo**, report them directly to [TypeScript ESTree](https://github.com/JamesHenry/typescript-estree).

‎package.json

+10-10
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
22
"name": "typescript-eslint-parser",
3-
"description": "An Esprima-style parser for TypeScript",
3+
"description": "An ESLint custom parser which leverages TypeScript ESTree",
44
"author": "Nicholas C. Zakas <nicholas+npm@nczconsulting.com>",
55
"homepage": "https://github.com/eslint/typescript-eslint-parser",
66
"main": "parser.js",
7-
"version": "19.0.1",
7+
"version": "20.0.0",
88
"files": [
99
"parser.js",
1010
"visitor-keys.js"
@@ -20,12 +20,12 @@
2020
"devDependencies": {
2121
"eslint-config-eslint": "4.0.0",
2222
"eslint-plugin-node": "6.0.1",
23-
"eslint-release": "0.11.1",
23+
"eslint-release": "1.1.0",
2424
"jest": "23.1.0",
2525
"npm-license": "0.3.3",
2626
"shelljs": "0.8.2",
2727
"shelljs-nodecli": "0.1.1",
28-
"typescript": "~3.0.1"
28+
"typescript": "~3.1.1"
2929
},
3030
"keywords": [
3131
"ast",
@@ -42,16 +42,16 @@
4242
"integration-tests": "docker-compose -f tests/integration/docker-compose.yml up",
4343
"kill-integration-test-containers": "docker-compose -f tests/integration/docker-compose.yml down -v --rmi local",
4444
"lint": "node Makefile.js lint",
45-
"release": "eslint-release",
46-
"ci-release": "eslint-ci-release",
47-
"gh-release": "eslint-gh-release",
48-
"alpharelease": "eslint-prerelease alpha",
49-
"betarelease": "eslint-prerelease beta"
45+
"generate-release": "eslint-generate-release",
46+
"generate-alpharelease": "eslint-generate-prerelease alpha",
47+
"generate-betarelease": "eslint-generate-prerelease beta",
48+
"generate-rcrelease": "eslint-generate-prerelease rc",
49+
"publish-release": "eslint-publish-release"
5050
},
5151
"dependencies": {
5252
"eslint": "4.19.1",
53-
"typescript-estree": "1.0.0",
5453
"eslint-visitor-keys": "^1.0.0"
54+
"typescript-estree": "2.1.0"
5555
},
5656
"peerDependencies": {
5757
"typescript": "*"

‎parser.js

+4
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,10 @@ exports.parseForESLint = function parseForESLint(code, options) {
3333
return { ast, visitorKeys };
3434
};
3535

36+
exports.parse = function(code, options) {
37+
return this.parseForESLint(code, options).ast;
38+
};
39+
3640
// Deep copy.
3741
/* istanbul ignore next */
3842
exports.Syntax = (function() {

‎tests/integration/declared-empty-body-functions-issue-162/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
"devDependencies": {
99
"eslint": "4.19.1",
1010
"jest": "23.1.0",
11-
"typescript": "~2.9.1"
11+
"typescript": "~3.1.1"
1212
}
1313
}

‎tests/integration/jsdoc-indent-issues-344-422/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
"devDependencies": {
99
"eslint": "4.19.1",
1010
"jest": "23.1.0",
11-
"typescript": "~2.9.1"
11+
"typescript": "~3.1.1"
1212
}
1313
}

‎tests/integration/method-overloads-issue-389/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
"devDependencies": {
99
"eslint": "4.19.1",
1010
"jest": "23.1.0",
11-
"typescript": "~2.9.1"
11+
"typescript": "~3.1.1"
1212
}
1313
}

‎tests/integration/no-redeclare-overloaded-functions-issue-402/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
"devDependencies": {
99
"eslint": "4.19.1",
1010
"jest": "23.1.0",
11-
"typescript": "~2.9.1"
11+
"typescript": "~3.1.1"
1212
}
1313
}

‎tests/integration/range-error-indent-issue-333/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@
88
"devDependencies": {
99
"eslint": "4.19.1",
1010
"jest": "23.1.0",
11-
"typescript": "~2.9.1"
11+
"typescript": "~3.1.1"
1212
}
1313
}

0 commit comments

Comments
 (0)
This repository has been archived.