首页 > 其他 > 详细

git工具

时间:2015-04-24 22:23:33      阅读:259      评论:0      收藏:0      [点我收藏+]

1.Git Bash常用命令:

pwd    当前工作目录

clear   清屏

ls   列举当前目录下的文件及文件夹

cd 更改目录

mkdir   创建目录

touch   创建空文件

cp 拷贝

rm 移除

mv   移动文件,可用来对文件重命名

date   当前日期

echo 回显

?2.基本Git命令-1:

?git add 

git commit

git push

git add . add all new files

git add -u updates tracking forfiles that changed names or were deleted

git add A does both 

git commit -m "message"

git push

branches

git checkout -b branchname-->create a branch  

git branch    see what branch you are on 

git checkout master   switch back to the master type

3.常用文件操作命令:

git status 查看文件状态

git add  跟踪新文件或暂存已修改文件

git diff  查看文件变化

git  commit –m <</span>msg> 提交更新

git rm file  移除文件

git  log 查看提交日志

git commit –ammend    修改最后一次提交

git reset HEAD  取消已暂存文件

git工具

原文:http://www.cnblogs.com/zhang88/p/4454546.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!