首页 > TAG信息列表 > ubuntuE470

git reset 回退版本

-先模拟提交过程,一共提交四次,每次都向文本里写一个新数 # 向文本中写入0 $ echo 0 >a.t $ git add . #第一次提交到仓库 $ git commit -m '0' # 向文本中写入1 $ echo 1 >a.t $ git add .; #第二次提交到仓库 $ git commit -m '1' # 向文本中写入2 $ echo 2 >a.t $ git add