在git中重命名一个文件,命令如下:
git mv readme2.txt readme3.txt
查看:
$ git status
On branch master
Changes to be committed:
(use "git reset HEAD <file>..." to unstage)
new file: readme3.txt
执行提交操作:
$ git commit -m "git study"
[master 5d8377f] git study
1 file changed, 0 insertions(+), 0 deletions(-)
create mode 100744 readme3.txt