consolidation/version-tool
Composer 安装命令:
composer require consolidation/version-tool
包简介
Template project for PHP libraries.
README 文档
README
The version-tool identifies the type and version of several popular projects.
Getting Started
Download the latest version-tool.phar from the releases page. Run chmod +x version-tool.phar, rename to version-tool, and move to some directory in your $PATH (e.g. /usr/local/bin).
version-tool will tell you what program and what version exists in the current working directory:
$ version-tool info
program: Drupal
version: 8.6.1
Detected frameworks:
- Drupal 8
- Drupal 7
- Drupal 6
- WordPress
Using the API
The Version Tool may also be included in another project as a library.
$ composer require consolidation/version-tool
Then, call as follows:
$version_info = new VersionTool();
$info = $version_info->info($path);
$app = $info->application();
$version = $info->version();
Running the tests
The test suite may be run locally by way of some simple composer scripts:
| Test | Command |
|---|---|
| Run all tests | composer test |
| PHPUnit tests | composer unit |
| PHP linter | composer lint |
| Code style | composer cs |
| Fix style errors | composer cbf |
Deployment
- Edit the
VERSIONfile to contain the version to release followed by "-dev", and commit the change. - Run
composer release
Contributing
Please read CONTRIBUTING.md for details on the process for submitting pull requests to us.
Versioning
We use SemVer for versioning. For the versions available, see the releases page.
Authors
- Greg Anderson - created project from template.
See also the list of contributors who participated in this project.
License
This project is licensed under the MIT License - see the LICENSE file for details
consolidation/version-tool 适用场景与选型建议
consolidation/version-tool 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 1.32M 次下载、GitHub Stars 达 1, 最近一次更新时间为 2018 年 09 月 30 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 consolidation/version-tool 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 consolidation/version-tool 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 1.32M
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 17
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-09-30