mirror of
https://github.com/zhamao-robot/zhamao-framework.git
synced 2026-03-18 05:04:51 +08:00
fix plugin:make autoload bug
This commit is contained in:
parent
6cc45aed43
commit
7f0761e545
@ -50,7 +50,7 @@ class Framework
|
||||
public const VERSION_ID = 715;
|
||||
|
||||
/** @var string 版本名称 */
|
||||
public const VERSION = '3.1.9';
|
||||
public const VERSION = '3.1.10';
|
||||
|
||||
/**
|
||||
* @var RuntimePreferences 运行时偏好(环境信息&参数)
|
||||
|
||||
@ -83,7 +83,8 @@ class PluginGenerator
|
||||
// TODO: 寻找 PHP 运行环境和 Composer 是否在当前目录的情况
|
||||
chdir($plugin_base_dir);
|
||||
$env = ZMUtil::getComposerExecutable();
|
||||
passthru(PHP_BINARY . ' ' . escapeshellcmd($env) . ' dump-autoload');
|
||||
$cmd = $env === 'composer' ? $env . ' dump-autoload' : PHP_BINARY . ' ' . escapeshellcmd($env) . ' dump-autoload';
|
||||
passthru($cmd);
|
||||
chdir(WORKING_DIR);
|
||||
return $plugin_base_dir;
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user