建立於: 2年前 ( 更新: 2年前 )
如何透過git指令顯示自己的版控?
這些指令僅供參考,至少應該改一下作者名稱哦。
--author的參數,也可以是信箱
單行日期區間
git log --pretty=oneline --since="2022-12-17" --until="2022-12-18" --author="devin"
格式化
git log --pretty=format:"%an --- %s" --since="2022-12-10" --until="2022-12-18" --author="devin"
查7天內自己的所有版控 (我們可以寫成別名,執行就會列出來很方便)
git log --pretty="format:%h %s -- %aD %cn" --since="7 days ago" --author=devin --stat
參數 | 說明 |
---|---|
--pretty | 可用的值: oneline, short, medium, full, fuller, email, raw, format |
format: "下方格式" %an 作者的名字 %H full SHA-1 hash 其他 %h abbreviated commit hash, %ae 作者信箱 %cn committer name, %ce commiter email, %cd 提交日期(committer date) %e encoding %s subject %n newline | |
--since | "yyyy-mm-dd" 開始日期 |
--until | "yyyy-mm-dd" 完成日期 |
--author | "John Doe" 作者名稱 |
No Comment
Post your comment