Git入门教程及使用步骤.docVIP

  • 0
  • 0
  • 约2.21千字
  • 约 17页
  • 2017-06-21 发布于湖北
  • 举报
Git入门教程及使用步骤

git入门教程 yangjian102621@163.com 一、名词解析 git工作流 工作目录 = 缓存区 = 最近提交 分支 分支是用来将特性开发绝缘开来的。在你创建仓库的时候,master 是“默认的”。在其他分支上进行开发,完成后再将它们合并到主分支上。 二、Git命令行操作 初始化一个git项目 cd {project_name} git init 克隆项目 git clone {project_url} 添加文件到版本控制 git add {filename} git add --all git add -A 删除文件 git rm {filename} 查看当前文件状态 git status 提交修改 git commit -m “xxx” 推送改变 git push {remote} {branch} 标签 git tag 1.0.0 1b2e1d63ff(唯一的提交ID) git push {remote} {tag_name} 添加分支 git branch {branch_name} 删除分支 git branch -d {branch_name} 切换分支 git checkout {branch_name} 更新与合并 git pull git pull {remote} {branch} git merge {branch} 文件比较 git dif

文档评论(0)

1亿VIP精品文档

相关文档