如何生成 git commit 的人类可读描述
以下命令假设你在仓库中至少有一个之前的标签:
git_describe.sh
git describe --long --tags --dirty示例输出:
git_describe_output.txt
v0.1.0-9-g68066f4-dirty这意味着我们在 v0.1.0 标签后的第 9 个 commit 上,commit ID 为 g68066f4,工作树是脏的,即有未提交的更改。
Check out similar posts by category:
Git, Version Management
If this post helped you, please consider buying me a coffee or donating via PayPal to support research & publishing of new posts on TechOverflow