Download the PHP package mitoop/ace without Composer
On this page you can find all versions of the php package mitoop/ace. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package ace
Ace
🥇 macOS 下优雅管理多版本 PHP 的命令行工具
简介
Ace 是一款 macOS 平台下的 PHP 多版本切换工具,灵感来自优秀的 laravel/valet
。
如果你本地安装了多个版本的 PHP,并希望在不同项目中使用不同版本,Ace 将是你不可或缺的工具。
只需在项目根目录下运行:
Ace 会自动为当前项目匹配最合适的 PHP 版本,无需手动切换。
快速命令参考
版本匹配逻辑
Ace 会按照以下优先级查找项目所需 PHP 版本:
- 当前目录中的
ace.json
- 当前目录中的
composer.json
- 系统环境变量中的默认 PHP 版本
例如:
支持语义化版本约束,详见 https://semver.org/lang/zh-CN/
安装方式
注意事项
- 支持的 PHP 版本为
>= 7.1
- 若版本约束为
^7.1
,且本地存在[email protected]
,[email protected]
,[email protected]
,[email protected]
,[email protected]
等版本,Ace 会选择 最高的[email protected]
,即[email protected]
- 若需固定版本,请在项目中创建
ace.json
并指定版本 - 首次运行会缓存所有已安装的 PHP 版本,加快后续执行速度。新增/移除 PHP 后请运行
ace clear
清除缓存 - 多版本 PHP 同时启用时,需注意
php-fpm
的监听端口冲突。建议使用不同端口,或通过 unix socket 方式运行 - 推荐使用 shivammathur/homebrew-php 安装旧版本 PHP
- 多版本 PHP 安装相同扩展(如
redis
)时可能冲突。可在对应版本下先卸载再安装 -
Composer 高版本对 PHP 有最低要求,例如:
可使用长期维护版:
灵感来源
✨ Inspired by the great laravel/valet
All versions of ace with dependencies
PHP Build Version
Package Version
The package mitoop/ace contains the following files
Loading the files please wait ....