Skip to content

Commit 0133113

Browse files
authored
EQPS-477: SVC Enhancements (#26)
* EQPS-477: Dynamically set the correct path for autoload.php based on the location of the ‘vendor’ folder * EQPS-477: Make zend-stdlib a required dependency
1 parent 2e19e12 commit 0133113

File tree

5 files changed

+138
-130
lines changed

5 files changed

+138
-130
lines changed

bin/svc

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,12 @@
55
* See COPYING.txt for license details.
66
*/
77

8-
require __DIR__ . '/../vendor/autoload.php';
8+
foreach ([__DIR__ . '/../../../autoload.php', __DIR__ . '/../vendor/autoload.php'] as $file) {
9+
if (file_exists($file)) {
10+
require $file;
11+
break;
12+
}
13+
}
914

1015
use Symfony\Component\Console\Application;
1116
use Magento\SemanticVersionChecker\Console\Command\CompareSourceCommand;

composer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@
99
"bin": ["bin/svc"],
1010
"require": {
1111
"php": "~7.1.3||~7.2.0||~7.3.0",
12-
"tomzx/php-semver-checker": "^0.13.0",
13-
"symfony/console": "~4.4.0",
1412
"phpstan/phpdoc-parser": "^0.3.5",
15-
"wikimedia/less.php": "~1.8.0"
13+
"symfony/console": "~4.4.0",
14+
"tomzx/php-semver-checker": "^0.13.0",
15+
"wikimedia/less.php": "~1.8.0",
16+
"zendframework/zend-stdlib": "^3.2.1"
1617
},
1718
"require-dev": {
1819
"phpunit/phpunit": "^6.5.0",
19-
"zendframework/zend-stdlib": "^3.2.1",
2020
"squizlabs/php_codesniffer": "^3.5"
2121
},
2222
"autoload": {

0 commit comments

Comments
 (0)