This repository was archived by the owner on Mar 6, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 7
Include all the completion-related extensions in this package (and other stories) #26
Merged
Merged
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
cf7f7ee
Adds completion extension
dantleech 0fdf51e
Migrated tests
dantleech 43fe263
Adds RPC extension
dantleech 82e2106
Migrated RPC extension test
dantleech 6ddb106
Adds worse extension
dantleech eb5cb4a
MIgrates worse tests
dantleech ef5351b
Dedicated RPC namespace
dantleech 4a762a6
Added ls extension
dantleech d30f507
Migrates LS tests
dantleech a51fb6d
Dedicated LS namespace
dantleech b9e74d2
Upgrade to PHPUnit 9
dantleech 87d5ab4
Applying PHPStan level 7
dantleech 84ae3fd
Finalized phpstan fixes
dantleech 8665dc7
Updated gitignore
dantleech 6fa8eef
Removd cache
dantleech 694aa66
Adds bin
dantleech 5a40e66
Updated README
dantleech 55a0912
Require PHP 7.3
dantleech 1162b48
Add bin to cs config
dantleech File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,3 +1,5 @@ | ||
| /.phpunit.result.cache | ||
| /cache | ||
| /vendor | ||
| /tests/Workspace | ||
| /tests/Assets/workspace | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,7 @@ | ||
| <?php | ||
|
|
||
| $finder = PhpCsFixer\Finder::create() | ||
| ->in('bin') | ||
| ->in('lib') | ||
| ->in('tests') | ||
| ->exclude([ | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,52 @@ | ||
| #!/usr/bin/env php | ||
| <?php | ||
|
|
||
| use Acme\Extension\StupidCompletion\StupidCompletionExtension; | ||
| use Phpactor\Completion\Extension\CompletionExtension; | ||
| use Phpactor\Completion\Extension\CompletionRpcExtension; | ||
| use Phpactor\Completion\Extension\CompletionWorseExtension; | ||
| use Phpactor\Completion\Extension\LanguageServerCompletionExtension; | ||
| use Phpactor\Container\PhpactorContainer; | ||
| use Phpactor\Extension\ClassToFile\ClassToFileExtension; | ||
| use Phpactor\Extension\ComposerAutoloader\ComposerAutoloaderExtension; | ||
| use Phpactor\Extension\Console\ConsoleExtension; | ||
| use Phpactor\Extension\LanguageServer\LanguageServerExtension; | ||
| use Phpactor\Extension\Logger\LoggingExtension; | ||
| use Phpactor\Extension\ReferenceFinder\ReferenceFinderExtension; | ||
| use Phpactor\Extension\Rpc\RpcExtension; | ||
| use Phpactor\Extension\SourceCodeFilesystem\SourceCodeFilesystemExtension; | ||
| use Phpactor\Extension\WorseReflection\WorseReflectionExtension; | ||
| use Phpactor\FilePathResolverExtension\FilePathResolverExtension; | ||
| use Phpactor\Indexer\Extension\IndexerExtension; | ||
| use Symfony\Component\Console\Application; | ||
|
|
||
| require __DIR__ . '/../vendor/autoload.php'; | ||
|
|
||
| $container = PhpactorContainer::fromExtensions([ | ||
| ConsoleExtension::class, | ||
| FilePathResolverExtension::class, | ||
| LoggingExtension::class, | ||
| SourceCodeFilesystemExtension::class, | ||
| WorseReflectionExtension::class, | ||
| ClassToFileExtension::class, | ||
| ComposerAutoloaderExtension::class, | ||
| RpcExtension::class, | ||
| LanguageServerExtension::class, | ||
| CompletionExtension::class, | ||
| LanguageServerCompletionExtension::class, | ||
| CompletionWorseExtension::class, | ||
| CompletionRpcExtension::class, | ||
| ], [ | ||
| FilePathResolverExtension::PARAM_APPLICATION_ROOT => __DIR__ . '/../', | ||
| WorseReflectionExtension::PARAM_ENABLE_CACHE => true, | ||
| LoggingExtension::PARAM_ENABLED => true, | ||
| LoggingExtension::PARAM_LEVEL => 'debug', | ||
| LoggingExtension::PARAM_PATH=> 'php://stderr', | ||
| LanguageServerExtension::PARAM_WELCOME_MESSAGE => 'Completion Test Application', | ||
| ]); | ||
|
|
||
| $application = new Application(); | ||
| $application->setCommandLoader( | ||
| $container->get(ConsoleExtension::SERVICE_COMMAND_LOADER) | ||
| ); | ||
| $application->run(); | ||
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,25 +3,35 @@ | |
| "minimum-stability": "dev", | ||
| "description": "Completion library for Worse Reflection", | ||
| "license": "MIT", | ||
| "prefer-stable": true, | ||
| "authors": [ | ||
| { | ||
| "name": "Daniel Leech", | ||
| "email": "[email protected]" | ||
| } | ||
| ], | ||
| "require": { | ||
| "php": "^7.2", | ||
| "phpactor/worse-reflection": "~0.2", | ||
| "php": "^7.3", | ||
| "phpactor/worse-reflection": "~0.4", | ||
| "phpactor/source-code-filesystem": "~0.1", | ||
| "phpactor/class-to-file": "~0.3", | ||
| "phpactor/text-document": "^1.0" | ||
| }, | ||
| "require-dev": { | ||
| "phpbench/phpbench": "^1.0@dev", | ||
| "phpunit/phpunit": "~7.0", | ||
| "phpactor/test-utils": "^1.0@dev", | ||
| "phpstan/phpstan": "~0.11.0", | ||
| "friendsofphp/php-cs-fixer": "~2.15.0" | ||
| "phpbench/phpbench": "^1.0", | ||
| "phpunit/phpunit": "~9.0", | ||
| "phpactor/test-utils": "^1.0", | ||
| "phpstan/phpstan": "~0.12.0", | ||
| "friendsofphp/php-cs-fixer": "~2.15.0", | ||
| "dms/phpunit-arraysubset-asserts": "dev-master", | ||
| "phpspec/prophecy-phpunit": "dev-master", | ||
|
|
||
| "phpactor/container": "^1.0", | ||
| "phpactor/logging-extension": "~0.1", | ||
| "phpactor/rpc-extension": "~0.1", | ||
| "phpactor/worse-reflection-extension": "~0.2", | ||
| "phpactor/source-code-filesystem-extension": "~0.1", | ||
| "phpactor/language-server-extension": "~0.2" | ||
| }, | ||
| "autoload": { | ||
| "psr-4": { | ||
|
|
@@ -39,9 +49,16 @@ | |
| } | ||
| }, | ||
| "scripts": { | ||
| "integrate": [ | ||
| "integrate-ci": [ | ||
| "vendor/bin/php-cs-fixer fix --dry-run", | ||
| "vendor/bin/phpstan analyse lib -c phpstan.neon", | ||
| "vendor/bin/phpunit", | ||
| "bin/completion" | ||
| ], | ||
| "integrate": [ | ||
| "vendor/bin/php-cs-fixer fix", | ||
| "vendor/bin/phpstan analyse lib -c phpstan.neon", | ||
| "bin/completion", | ||
| "vendor/bin/phpunit" | ||
| ] | ||
| } | ||
|
|
||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not indexer (also include this in phpcs fixer)