1
0
Fork 0
Commit Graph

45 Commits (83a1618885fede455ea5f19f2b8580bd63ee8586)

Author SHA1 Message Date
Felix Becker f00fd1b62c
fix(formatting): drop PHP CodeSniffer (#504)
At this point there are countless issues about the formatting done by CodeSniffer. It plain out doesn't work in many cases, overrides format options that are contributed by other extensions in VS Code and does not reuse any of our AST parsing. For that reason, I am starting to think there is no reason to keep it in here until we have proper pretty-printing support from https://github.com/Microsoft/tolerant-php-parser that actually reuses our ASTs and can work while editing. For people who want to use CodeSniffer to format their code, there could be a standalone CodeSniffer language server (like there is a TSLint language server and ESLint language server). As said, we don't reuse our state anyway.

BREAKING CHANGE: removes formatting support

closes #501
closes #474
closes #473
closes #468
closes #450
closes #445
closes #443
closes #423
closes #343
closes #296
closes #293
closes #499
closes #471
2017-11-04 23:57:51 -07:00
Felix Becker ac6bce929f chore: get patch versions of tolerant-php-parser 2017-10-30 22:51:23 -07:00
Felix Becker 16cf8f53e9 fix(docblocks): update to phpdocumentor/reflection-docblock ^4.0.0
closes #139
2017-10-22 21:30:38 -07:00
Felix Becker 1240f25e01 Update parser 2017-10-19 14:45:36 -07:00
Felix Becker e31f7b5923 Add more Composer scripts 2017-10-19 14:38:20 -07:00
Vincent Klaiber 0c399150a3 Update travis and phpunit (#489) 2017-10-02 14:11:06 -07:00
Vincent Klaiber b9ebfb52c9 Update composer.json structure (#487) 2017-10-02 13:58:37 -07:00
Rob Lourens 63bf43e40c Bump tolerant-php-parser to get fix (#457)
for https://github.com/Microsoft/tolerant-php-parser/issues/12
2017-08-11 10:29:55 -07:00
Felix Becker 7ce2284176 Pin phpdocumentor/reflection-docblock dependency
https://github.com/phpDocumentor/ReflectionDocBlock/issues/109
2017-07-19 13:15:48 +02:00
Rob Lourens f97105740d Bump tolerant-php-parser (#415)
* Bump tolerant-php-parser

* Update test for new parser static support
2017-06-17 10:53:08 +02:00
Felix Becker 548120314d Revert "Update CodeSniffer"
This reverts commit 663ccd5f23.
2017-06-16 20:39:32 +02:00
Felix Becker 663ccd5f23 Update CodeSniffer 2017-06-15 17:11:57 +02:00
Sara Itani 7f427a1215 Adopt Microsoft/tolerant-php-parser (#357) 2017-06-09 20:25:30 +02:00
Jens Hausdorf 97d1579f37 Update PHPParser dependency (#345) 2017-04-09 18:23:46 +02:00
Sara Itani 7f8eccb5ae Fix formatting breakage (option 2) (#324)
PHP_CodeSniffer 3.0 RC4 introduces a breaking change that removes PHPCS from the composer autoloader. This fix addresses the issue by locking to v3.0 RC3.
2017-03-02 10:07:47 +01:00
Felix Becker 3856f4f46a Update PHPParser 2017-02-15 11:16:16 +01:00
Cameron Eagans 34d3d2030d Automatically index stubs on composer install (#269) 2017-02-02 18:36:48 +01:00
Cameron Eagans 7fbd68a61a Depend on phpcs RC2 (#268) 2017-02-02 02:06:16 +01:00
Felix Becker d8823bc7dc Use JetBrains PHPStorm stubs from packagist (#264)
* Use JetBrains PHPStorm stubs from packagist

* Fix path
2017-01-30 11:55:13 +01:00
Felix Becker 47b5b6709c Restart without XDebug if enabled (#259) 2017-01-26 02:08:40 +01:00
Felix Becker cd116a252b Update php-parser 2016-12-13 10:07:11 +01:00
Felix Becker a7d77d844e Add Index classes and stubs (#214) 2016-12-13 01:51:02 +01:00
Felix Becker 10fb3c92e0 Completion (#165)
* Add support for method/property completion

* Move completion fixtures into directory

* Add support for variable suggestions

Refactor logic into CompletionProvider class

* Allow getTypeFromNode() to take Variable nodes

* Use property and constant values

* Fix using @var tag for variables

* Improve completion

* classes
* variables with prefix filtering

* Make FQNs more distinct

* use -> for instance methods/properties
* use ::$ for static properties

* Add tests for static access

* Properly filter completion on empty property

* Fix existing tests

* Add support for static access without prefix

* Fix testFullyQualifiedClass

* Add missing fixtures

* Correct file number in init test

* Only insert backslash if not typed yet

* Completion for keywords and bug fixes

* Correct variable insertion

* Support completion for namespaces

* Use CompletionList

* Always set isIncomplete to true

* Update PHPCodeSniffer

* Remove unused method

* And the call

* Handle case where FQN could not be resolved
2016-11-30 22:23:51 +01:00
Felix Becker 33211c68ca Resolve expressions recursively (#155)
* Add Definition class
* Add recursive DefinitionResolver
* Cache hover
2016-11-18 15:22:24 +01:00
Michal Niewrzal 50490d51ea Fix formatting makes LS non-responsive (#153) 2016-11-18 14:25:05 +01:00
Felix Becker 500ae5dc92 Use custom error handler instead of Symfony (#162) 2016-11-18 14:15:08 +01:00
Felix Becker 601c9ad997 Update PHPParser to 3.0.0beta2 (#151) 2016-11-16 16:58:32 +01:00
Felix Becker 03bbf5f4ba Enable LS to operate without accessing the file system (#136)
This PR decouples the LS from direct file system access by implementing the proposals for workspace/files and textDocument/content under workspace/xfiles and textDocument/xcontent. The requests are only used when the client expressed support for them through ClientCapabilities, otherwise direct FS access is used.
This turns document content retrieval and recursive file search into async operations.
In turn, all server handlers can now operate async by returning a promise.
2016-11-14 10:25:44 +01:00
Felix Becker 92145c526e Update sabre/event to 5.0 2016-10-27 00:03:09 +02:00
Felix Becker 18e58b4ce8 Update php-parser to latest commit (#119) 2016-10-26 22:25:24 +02:00
Felix Becker 953a8023b7 Update AdvancedJsonRpc (#103) 2016-10-20 03:31:12 +02:00
Felix Becker 96694996f7 Refactor FQN functions to own namespace (#100) 2016-10-20 01:00:20 +02:00
Felix Becker 6fe01183b0 References (#52)
* Adds support for textDocument/references
* Adds tests for global definitions and global fallback
2016-10-12 01:45:15 +02:00
Felix Becker 23b127a986 Add Symfony ErrorHandler (#58) 2016-10-11 14:50:10 +02:00
Michal Niewrzal e75c1592fc Use PHP_CodeSniffer as a formatter (#35)
Also adds uriTopath util function
2016-10-10 15:06:02 +02:00
Stephan Unverwerth 501d26e1d4 Global symbol search (#31)
* Implemented workspace symbol search

* Fixed missing TextEdit using declaration

* Fixed generating uri when parsing next file.

* Cleaned up code. Fixed tests

* Fixed PHPDoc for LanguageServer::initialize()

* Moved utility functions to utils.php

* Added tests for pathToUri and findFilesRecursive

* Added command line argument for socket communication

* Fixed local variable detection and containerName generation in SymbolFinder

* Fixed formatting in ProtocolStreamReader

* Store text content in PHPDocument, removed stmts, regenerate on demand

* Fixed local variable detection and containerName generation in SymbolFinder.

* Added Tests for Project and Workspace

* Added test for didChange event

* Modified lexer error handling

* Removed file that shouldn't have been committed.

* Updated sabre/event dependency to 4.0.0

* Updated readme.md to show tcp option

* make input stream non-blocking

* Correct code style

* Use triple equals

* Revert change in SymbolFinder

* Optimize processFile() a bit

* Use MessageType enum instead of number literal

* Add missing space

* Fixed ProtocolStreamWriter for nonblocking connection.

* Suppress fwrite() notice when not all bytes could be written.

* Fix another code style issue

* Throw Exceotion instead of Error

* Added ProtocolStreamWriter test

* Correct workspace/symbol documentation

* Improve exception in ProtocolStreamWriter::write()
2016-09-30 11:30:08 +02:00
Felix Becker 41e9fb7e8a Update PHPParser to 3.0.0beta1 (#33) 2016-09-23 18:56:04 +02:00
Felix Becker 4fc2a6c2e4 Add coverage reporting (#14)
* Add coverage reporting

* Add badge

* Add codecov.yml
2016-09-06 12:55:05 +02:00
Felix Becker f1a53a93de Rename bin entry 2016-08-25 16:23:28 +02:00
Felix Becker f33fda952f Remove version field from composer.json 2016-08-25 15:32:18 +02:00
Felix Becker 41ad025fe7 Update 2016-08-25 15:27:14 +02:00
Felix Becker 770a7aa90d Add PHPUnit 2016-08-23 09:07:14 +02:00
Felix Becker 4682f8790a Update composer.json 2016-08-22 22:51:17 +02:00
Felix Becker 64e496fac9 Update 2016-08-22 17:32:31 +02:00
Felix Becker b1656f6884 Initial Commit 2016-08-12 10:16:42 +02:00