caherrera / gitinfo
1.0.4
2019-08-23 16:06 UTC
Requires
- php: ^7.1.3
- ext-json: *
- illuminate/support: ^5.8
- symfony/console: ^4.3
- symfony/process: ^4.3
Requires (Dev)
- phpunit/phpunit: ^7.5
README
此包提供了一个控制台应用程序,用于获取文件夹的git信息
零配置使用
如果您不需要任何自定义的补全行为,只需将补全命令添加到您的应用程序中即可
- 使用
composer
安装caherrera/gitinfo
,运行以下命令:$ composer global require caherrera/gitinfo
工作原理
要运行,请在任何控制台中输入以下命令
$ ~/vendor/caherrera/gitinfo/console [/path/to/scan]
示例
$ ~/vendor/caherrera/gitinfo/console $(pwd) {"commit":"a2986ed961f6aa628a647df9e8f04892c38480f3","hash":"a2986ed","created":"2019-08-21 19:21:45","author":"Carlos Herrera","email":"carlos.herrera@viajesfalabella.com","repository":"git@github.com:caherrera\/gitinfo.git","status":"[{\"file\":\"M\",\"status\":\"\"},{\"file\":\"M\",\"status\":\"\"}]","branch":"master","tag":"1.0.1","project":"gitinfo"}
此命令将以json格式返回信息