Skip to content
This repository has been archived by the owner on Nov 29, 2020. It is now read-only.

Commit

Permalink
fixed including extension.neon from phpstan.phar
Browse files Browse the repository at this point in the history
  • Loading branch information
fprochazka committed May 5, 2017
1 parent 321fc3d commit 0cd7738
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
13 changes: 13 additions & 0 deletions patches/nette/di/include-scheme.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git i/src/DI/Config/Loader.php w/src/DI/Config/Loader.php
index 6e0ce50..03a728e 100644
--- i/src/DI/Config/Loader.php
+++ w/src/DI/Config/Loader.php
@@ -48,7 +48,7 @@
if (isset($data[self::INCLUDES_KEY])) {
Validators::assert($data[self::INCLUDES_KEY], 'list', "section 'includes' in file '$file'");
foreach ($data[self::INCLUDES_KEY] as $include) {
- if (!preg_match('#([a-z]:)?[/\\\\]#Ai', $include)) {
+ if (!preg_match('#([a-z]+:)?[/\\\\]#Ai', $include)) {
$include = dirname($file) . '/' . $include;
}
$merged = Helpers::merge($this->load($include), $merged);
6 changes: 6 additions & 0 deletions src/Compiler/Compiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ class Compiler
'url' => self::PATCHES_DIR . '/nikic/php-parser/prefixing.patch',
],
],
'nette/di' => [
[
'title' => 'Fixed including of paths with scheme in config loader',
'url' => self::PATCHES_DIR . '/nette/di/include-scheme.patch',
],
],
],
],
],
Expand Down

2 comments on commit 0cd7738

@lookyman
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, I've run into this just a few hours ago!

@fprochazka
Copy link
Owner Author

@fprochazka fprochazka commented on 0cd7738 May 5, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lookyman can you try https://github.com/phpstan/phpstan-shim/tree/0.6.x ? :)

It is not yet on packagist, so you have to add it as composer repo

Please sign in to comment.