adt / tracy-git
此包已被废弃且不再维护。未建议替换包。
Tracy 控板 Git 提交信息
v1.2.1
2021-10-20 19:06 UTC
Requires (Dev)
- nette/nette: ^2.4 || ~3.0
README
查看 https://github.com/AppsDevTeam/tracy-system-info
Tracy Git 控板
用于显示当前部署的应用版本信息。
安装
Composer
composer require adt/tracy-git
config.neon
extensions: tracyGit: ADT\TracyGit\DI\TracyGitExtension tracyGit: provider: json file: %appDir%/git.json
当前支持的提供者是
json
- 需要指定
file
并存在
- 需要指定
更新 Git 信息
JSON 提供者
运行 vendor/bin/tracy-git-json app/git.json
- 使用
-h
或--help
显示使用说明, - 使用
--with-user
包含当前 Git 用户, - 使用
--with-timestamp
包含当前时间戳
注意:不要忘记将 app/git.json
添加到您的 .gitignore
。
自动更新
大多数部署系统都有在部署实际发生之前要执行的命令列表。
例如,对于 dg/ftp-deployment
和 JSON 提供者
-
ini 配置
before[] = local: vendor/bin/tracy-git-json app/git.json --with-user
-
php 配置
$before[] = 'local: vendor/bin/tracy-git-json app/git.json --with-user';