【发布时间】:2014-02-22 03:00:29
【问题描述】:
如何做这样的事情:
-
创建一个包含以下内容的:
$ cat testfile.txt
此文件将使用以下 id 提交:83b90a07620ef578450c40a6d38bacc42de7ad2d 提交 testfile.txt
$ git add testfile.txt
$ git commit -m '谢谢'执行 git log 以验证预测的提交 ID:
$ 混帐日志
提交 83b90a07620ef578450c40a6d38bacc42de7ad2d
作者:rohit01 *@gmail.com>
日期:2014 年 2 月 21 日星期五 23:46:52 +0530
基本上,预测下一个 git commit id 并提交一个包含该提交 id 的文件。
【问题讨论】:
-
我很好奇这个用例是什么。当提交 id 可从
git log获得时,为什么要保存它? -
用例:我在 github (github.com/rohit01/rohit01.github.io) 中托管我的博客。我想写一篇博客来解释它是如何工作的,并分享同一个博客的 github 提交链接。
标签: git