I'm trying to generate some release notes using the following:
git log --pretty=format:%s my-project-1.2..HEAD
However, how can I reuse something similar to this generically after each new rev instead of specifying the last known good rev (everytime) to work from (one down from head)?
ie
git log --pretty=format:%s [somehow get my-project-last-rev so I don't have to specify]..HEAD
git describe --abbrev=0 --tags
应该为您提供当前分支“下”的最新标签,因此您可以使用反git describe --abbrev=0 --tags
内联执行它:
git log --pretty=format:%s `git describe --abbrev=0 --tags`..HEAD
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.