Commit graph

222 commits

Author SHA1 Message Date
Sheetal Nandi 09f0b3471a Merge branch 'master' into ownJsonParsing 2017-06-15 09:59:37 -07:00
Sheetal Nandi 187febd10f Merge pull request #16494 from Microsoft/dontCreateScriptInfosWithFileExistsAndReadFile
Fixes the memory leak because of project and its corresponding script info even after project is removed
2017-06-14 15:17:25 -07:00
Sheetal Nandi 1bf1209f7e Cleanup script infos that are not part of any project when the project is closed or inferred projects are refreshed
Also dispose some pointers so that the closures get disposed with project and script infos
2017-06-12 16:52:36 -07:00
Andy 09321b3834 Convert Extension to a string enum (#16425) 2017-06-09 19:32:44 -07:00
Sheetal Nandi c4ad151a46 Merge branch 'master' into ownJsonParsing 2017-06-05 17:01:09 -07:00
Andy 70564110c0 Make use of array helper functions (#16226)
* Make use of array helper functions

* Remove unnecessary 'ts.'
2017-06-05 14:11:43 -07:00
Ryan Cavanaugh 6f42f9ae3f Merge pull request #15308 from chuckjaz/external-files
Allow plugins to provide a list of external files.
2017-06-05 13:14:25 -07:00
Sheetal Nandi d680720f6d Merge branch 'master' into ownJsonParsing 2017-06-05 10:28:23 -07:00
Andrew Casey 95b5a691d4 Guess 1: null check is missing; Guess 2: ternary does the appropriate check 2017-05-31 16:30:27 -07:00
Sheetal Nandi 8d771ca044 Merge branch 'master' into ownJsonParsing 2017-05-30 13:03:23 -07:00
Sheetal Nandi 7bd9e092ac Make configFile on compiler options as non enumerable 2017-05-26 17:15:57 -07:00
Andy d052bb83ca Add project telemetry (#16050)
* Add project telemetry

* Respond to some PR comments

* Wrap event in a TelemetryEvent payload

* Replace paths with empty string instead of removing them entirely

* Add "version" property to payload

* Add telemetry for typeAcquisition settings

* Add "files", "include", "exclude", and "compileOnSave"

* Convert typingsOptions include and exclude to booleanss

* Add "extends", "configFileName", and "projectType"

* configFileName: Use "other" instead of undefined

* Add "languageServiceEnabled" telemetry
2017-05-25 13:30:27 -07:00
Sheetal Nandi f1ea38d127 Merge branch 'master' into ownJsonParsing 2017-05-24 12:46:29 -07:00
Andy Hanson 34bb955655 Use orderedRemoveItem instead of remove helper 2017-05-24 08:42:02 -07:00
Sheetal Nandi 7cf93f94d4 Report config file errors as part of syntactic diagnostic on the file 2017-05-23 15:56:20 -07:00
Ryan Cavanaugh ab3ffa22da Add flag to allow local plugin loading 2017-05-17 19:52:57 -07:00
Sheetal Nandi ea60e9966d Get configFiles as part of file names 2017-05-15 16:07:08 -07:00
Chuck Jazdzewski 785c281fd6 Allow plugins to provide a list of external files.
The list of the plugin's external files and request made to
a file in the list will be routed to an instance of the plugin.
2017-04-25 10:11:05 -07:00
Arthur Ozga 0ea1b82a85 test module reuse 2017-04-20 18:55:15 -07:00
Arthur Ozga cbbf6f8847 Merge branch 'master' into tripleEquals 2017-04-17 15:57:51 -07:00
Ryan Cavanaugh d31364c09c Load global plugins even if no local ones exist 2017-04-13 16:17:35 -07:00
Ryan Cavanaugh 19ddc1e94a Avoid loading duplicate local+global plugins 2017-04-13 16:17:34 -07:00
Ryan Cavanaugh 3cc379c3c0 Fix merge 2017-04-13 16:16:57 -07:00
Arthur Ozga 7e03429a8e enforce triple-equals 2017-04-04 15:51:13 -07:00
Ryan Cavanaugh 71e296042a Apply the 20 MB non-TS source limit across all projects
(cherry picked from commit cc8ce5975c)
(cherry picked from commit de8fb9e833)
2017-03-24 11:58:20 -07:00
Andy Hanson d58cfa238b Merge branch 'master' into lint_better 2017-03-06 06:20:48 -08:00
Andy Hanson 8371eb6401 Update tslint to latest (next is still on 4.3) and lint for BOM 2017-03-01 10:37:13 -08:00
Andy Hanson 5ea43c8ba3 Merge branch 'master' into semicolon 2017-03-01 08:09:59 -08:00
Ryan Cavanaugh 87b780d641 Merge pull request #12231 from RyanCavanaugh/ls-proxy
Language service proxy
2017-02-14 14:16:23 -08:00
Ryan Cavanaugh aec310996c Language service extensibility 2017-02-14 13:35:16 -08:00
Andy Hanson 91421c8dbc Fix "semicolon" lint rule options (was not enabled) 2017-02-10 12:24:10 -08:00
Jason Ramsay 3480fcc69a Always set allowNonTsExtensions for allowJs 2017-02-10 11:13:12 -08:00
Andy Hanson 30462e11ef Merge branch 'master' into map5 2017-01-11 12:24:47 -08:00
Zhengbo Li 9e127967b6 Merge pull request #11603 from zhengbli/11116
Set maxNodeModuleJsDepth for inferred projects
2017-01-10 12:17:43 -08:00
Andy Hanson 8c5afd7f54 Merge branch 'master' into map5 2017-01-06 13:03:34 -08:00
Joel Day 3a9a136e51 Changes based on feedback.
Whitespace cleanup.
Switching back to protocol.ts and reenabling stripInternal.
Marking internal symbols indirectly exported by dependencies of protocol.ts as internal.
2017-01-04 15:56:16 -08:00
zhengbli 8ac22ecbb0 Change the design to track addRoot and removeRoot 2016-12-29 17:00:04 -08:00
zhengbli 09fc3b3a18 address cr feedback 2016-12-29 10:26:34 -08:00
zhengbli bf5faa04a6 Use inherited setCompilerOptions for inferred project 2016-12-28 14:46:58 -08:00
Andy Hanson 932eaa3f90 Rename and consolidate map iteration helpers 2016-12-28 09:16:38 -08:00
Andy Hanson 39c19a74ea Inline keysOfMap and valuesOfMap. 2016-12-28 09:05:52 -08:00
zhengbli a8a1a826b3 set the option when creating inferred projects 2016-12-28 08:15:21 -08:00
zhengbli 8648239e64 Merge branch 'master' of https://github.com/Microsoft/TypeScript into 11116 2016-12-28 04:07:04 -08:00
Andy Hanson 9e33585a80 Merge branch 'master' into map5 2016-12-27 12:56:05 -08:00
Vladimir Matveev 1045f3bffb detach root files on project close if project language service is disabled (#13077) 2016-12-20 19:25:25 -08:00
Vladimir Matveev e68161adfa when language service is disabled - build program using only open files (#12809) 2016-12-13 13:21:32 -08:00
Andy Hanson 55fc62bc45 Merge branch 'master' into map5 2016-12-12 07:50:09 -08:00
Jason Ramsay 5829ca82d0 use localUse local updatedFileNames - this way we'll know that set of names is definitely cleared 2016-12-09 14:44:08 -08:00
Jason Ramsay 5f46e488b7 Mark containing project as dirty when file is closed
(Note: adding this until PR #12789 is merged in so that unit tests pass)
2016-12-09 11:12:00 -08:00
Jason Ramsay 4cb5a36cb4 Merge branch 'master' into tsconfigMixedContentSupport 2016-12-09 10:58:33 -08:00
Jason Ramsay d52894302a Changes due to CR comments 2016-12-08 17:56:08 -08:00
Vladimir Matveev 7da3383504 do not use ScriptVersionCache for closed files (#12777) 2016-12-08 16:17:42 -08:00
Andy Hanson 6b1cc8972d Use native maps when they're available 2016-12-08 06:40:31 -08:00
Jason Ramsay 7a11453e35 Fix merge issues 2016-12-07 15:45:41 -08:00
Jason Ramsay 1c3689edef Merge branch 'master' into tsconfigMixedContentSupportRedux 2016-12-07 15:33:42 -08:00
Jason Ramsay 64dad30ca0 Reduced version from CR comments 2016-12-07 15:31:46 -08:00
zhengbli f6f866e88c Reset the noEmitForJsFiles option when updating compiler options (#12570) 2016-11-29 23:30:14 -08:00
Vladimir Matveev c05bf3b0a2 respect casing when comparing names of config files (#12474) 2016-11-23 12:34:00 -08:00
Jason Ramsay 5a9451ae23 Rename typingOptions.enableAutoDiscovery to typeAcquisition.enable 2016-11-18 18:14:32 -08:00
Jason Ramsay 464bc0e9e0 Merge branch 'master' into tsconfigMixedContentSupportRedux 2016-11-18 16:15:15 -08:00
Jason Ramsay 7dd30dbfd4 tsconfig.json mixed content support 2016-11-18 15:51:28 -08:00
Vladimir Matveev a2b13d05f2 pass project name as a constructor parameter (#12333) 2016-11-17 15:12:32 -08:00
Vladimir Matveev 36511838a4 allow getting compiler options diagnostics when language service is disabled 2016-11-14 10:41:48 -08:00
Vladimir Matveev 3b09010c7c enable syntactic features if project size exceeded the limit, send events when state of language service changes 2016-11-11 17:35:11 -08:00
Zhengbo Li 4dc58dde38 Exclude js files in non-configured projects compile-on-save emitting (#12118)
* Exclude js files in non-configured projects CoS emitting

* remove unnecessary method
2016-11-10 14:12:24 -08:00
Vladimir Matveev 9e3d6efb19 reduce set of files being watched, increase polling interval (#12054) (#12092) 2016-11-07 21:13:11 -08:00
Zhengbo Li 1c004bf317 Port #12027, #11980 and #11932 to master (#12037)
* add test for the fix for overwrite emitting error

* cr feedback
2016-11-03 21:13:41 -07:00
Zhengbo Li 4513ae3034 disable CoS for inferred projects (#11909) 2016-10-27 18:00:21 -07:00
Andy Hanson 12f6dcefa1 Revert "Merge pull request #11354 from Microsoft/map4"
This reverts commit adfdae0dc4, reversing
changes made to aad663cebf.
2016-10-27 15:50:21 -07:00
Andy Hanson bcc0807198 Respond to PR comments 2016-10-27 13:14:56 -07:00
Andy Hanson c958c47ef5 Merge branch 'master' into map4 2016-10-26 11:05:51 -07:00
Vladimir Matveev 7890f63250 use unresolved imports as a source of used typings (#11828) 2016-10-25 15:24:21 -07:00
Andy Hanson f828bc3fae Merge branch 'master' into map4 2016-10-18 09:07:00 -07:00
Vladimir Matveev 121f51e552 Merge pull request #11694 from Microsoft/vladima/reload-tmp
allow reload from temp files
2016-10-17 23:20:39 -07:00
zhengbli 536d703d9e Set maxNodeModuleJsDepth for inferred projects 2016-10-12 18:05:01 -07:00
Andy Hanson e8c7224eac Merge branch 'master' into map4 2016-10-12 08:50:49 -07:00
Zhengbo Li 460de66311 Turn on skipLibCheck for js-only inferred project and external project (#11399)
* Turn on skipLibCheck for js-only inferred project and external project

* avoid changing compiler options

* Update tests
2016-10-11 19:19:40 -07:00
Andy Hanson aadcbcc083 Use native maps when they're available 2016-10-06 13:29:18 -07:00
Vladimir Matveev 8177bd4da0 replace hardcodes 'useCaseSensitiveFileNames=false' in services with actual value, use specialized map lookup methods instead of generic 'getOrCreate*' 2016-09-30 13:19:54 -07:00
Ryan Cavanaugh 8c899a6c60 An elegant weapon for a more civilized age 2016-09-20 16:52:34 -07:00
Ryan Cavanaugh 3c7b213a8c PR updates 2016-09-20 12:07:52 -07:00
Ryan Cavanaugh 46dfd68ef8 Always return [] 2016-09-19 18:00:42 -07:00
Ryan Cavanaugh 6de3dc4f8b Cleanup 2016-09-19 17:04:51 -07:00
Ryan Cavanaugh 2612a74f63 Working version 2016-09-19 17:04:51 -07:00
Zhengbo Li 3c20df5e93 Create folders for sys.writeFile if folder doesn't exist (#10848)
* Create folders for sys.writeFile

* Use project root path for emit output file name

* Normalize project file path for external projects

* Patch writeFile for all sys implementations

* Use the original file for single inferred project case

* recursive create directory for all sys implementations
2016-09-13 16:20:42 -07:00
jramsay 4fc38fb1bf Merge pull request #10673 from Microsoft/tsserverVS-Types2.0
Updating TSServer to use @Types instead of TSD for d.ts auto acquisition
2016-09-02 15:45:01 -07:00
Zhengbo Li a3cd7d8c97 Avoid returning type symbols for js configured projects (#10654)
* Exclude all things from .d.ts files for projects containing only .js and .d.ts files
2016-09-01 15:17:38 -07:00
Zhengbo Li 95378aa399 Fix compile on save issues (#10615)
* only return .ts and .tsx files for affected document list
* Return all files exclude mixed-content files for CoS affected list
2016-08-31 12:11:32 -07:00
Jason Ramsay d15381682b - invalidate typings fix
- update gc timer
2016-08-30 15:51:43 -07:00
Jason Ramsay ba50c6eb25 Merge branch 'tsserverVS-WIP' into tsserverVS-Types2.0 2016-08-30 13:43:33 -07:00
Jason Ramsay 24ef426fbb Install packages separately 2016-08-30 13:41:24 -07:00
Zhengbo Li 1fb969f107 Split tests and fix issues with missing referenced files (#10599)
* Split tsserver project system tests to seperate files

* fix issues with missing references

* Incorporate changes in tsserverVS-WIP branch

* drop ts prefix
2016-08-30 11:47:08 -07:00
Jason Ramsay 456227bbee Move invalidate typings cache to UpdateGraphWorker 2016-08-29 16:43:34 -07:00
Jason Ramsay 6ea624a2fe Merge branch 'tsserverVS-WIP' into tsserverVS-Types2.0 2016-08-29 16:23:10 -07:00
Vladimir Matveev ce02f8319e use ScriptKind instead of file extension 2016-08-29 15:56:37 -07:00
Jason Ramsay a2f92aa583 invalidate cached typings on add or remove file 2016-08-29 15:44:33 -07:00
Vladimir Matveev 8075a0dd72 store project errors on project so they can be reported later 2016-08-26 14:37:49 -07:00
Zhengbo Li eea2dddfe1 Correct default compileOnSave value for different projects (#10528) 2016-08-25 10:46:41 -07:00
Vladimir Matveev dd979e8ede added more tests for cases when typingOptions are provided by external projects, set typing options after root files are added 2016-08-24 13:37:07 -07:00
Zhengbo Li a082857ae8 Add APIs for enabling CompileOnSave on tsserver (#9837)
* Add API to get only the emited declarations output

* Add nonModuleBuilder

* Add basic tests for CompileOnSaveAffectedFileList API

* Add API for compile single file

* Avoid invoking project.languageService directly

* Add API to query if compileOnSave is enabled for a project

* Seperate check and emit signatures

* Use Path type for internal file name matching and simplifying builder logic

* Always return cascaded affected list

* Correct the tsconfig file in compileOnSave tests
Also move the CompileOnSave option out of compilerOptions

* Reduce string to path conversion
2016-08-23 16:11:52 -07:00
Vladimir Matveev d736db3b01 add typingOptions to the protocol.ExternalProject 2016-08-23 15:15:12 -07:00
Vladimir Matveev 3f18fbc145 introduce branded type for TypingsArray 2016-08-17 16:42:05 -07:00
Vladimir Matveev a2e5c2d2b5 merge with origin/master 2016-08-17 14:38:30 -07:00
Vladimir Matveev 9a180122a5 merge with origin/master 2016-08-14 11:42:08 -07:00
Vladimir Matveev b1871a5bf9 [WIP] pass ITypingsInstaller to ProjectService 2016-08-12 14:01:23 -07:00
Vladimir Matveev d8d117ffaf [WIP] typings discovery in tsserver 2016-08-12 11:04:43 -07:00
Vladimir Matveev de37f35f7c set compilation settings of project as a part of sync process 2016-08-01 17:12:15 -07:00
Vladimir Matveev 6d497e3840 allow to change configuration for inferred projects 2016-07-31 22:06:41 -07:00
Vladimir Matveev bb016148da call updateGraph before getting language service 2016-07-22 16:01:54 -07:00
Vladimir Matveev aea1534704 move saveTo to ScriptInfo 2016-07-11 19:51:14 -07:00
Vladimir Matveev ac9717dc3d use Logger directly 2016-07-11 19:44:23 -07:00
Vladimir Matveev 9b4823e536 more tests 2016-07-05 15:51:39 -07:00
Vladimir Matveev bebc5711cb more tests 2016-06-30 13:23:55 -07:00
Vladimir Matveev d7bf32270e remove multiple collections for open files 2016-06-28 17:45:29 -07:00
Vladimir Matveev 24a6e50195 added tests 2016-06-27 15:29:04 -07:00
Vladimir Matveev 96a867a52e add support for single inferred project 2016-06-27 14:25:43 -07:00
Vladimir Matveev 417c1254eb fix casing 2016-06-24 17:27:18 -07:00
Vladimir Matveev 4157655215 [in progress] project system work - fixes in tests 2016-06-24 14:55:12 -07:00
Vladimir Matveev cefaa171eb [in progress] project system work - major code reorg 2016-06-24 14:30:45 -07:00
Vladimir Matveev cf616dc292 [in progress] project system work - path normalization 2016-06-22 17:02:08 -07:00
Vladimir Matveev c8d37dc87e [in progress] project system work - versions 2016-06-22 16:51:09 -07:00
Vladimir Matveev c9b82eddda [in progress] project system work 2016-06-21 17:31:54 -07:00