美文网首页
Git管理版本

Git管理版本

作者: SodaSea | 来源:发表于2017-07-05 11:19 被阅读0次

    安装以及建立仓库

    参考:http://1ke.co/course/194
    常见错误: http://blog.csdn.net/dengjianqiang2011/article/details/9260435
    上传新仓库: http://blog.csdn.net/u010520912/article/details/18993001

    常用命令

    本地删除替换文件后push到github

    git commit -am "some commit message"
    git push origin branch_name

    跟踪所有文件

    git add --all

    删除文件

    git rm --cached filename

    合并到本地 --allow-unrelated-histories是可选项

    git pull origin master --allow-unrelated-histories

    连接到远程主机(本地仓库建立好之后,push之前)

    git remote add origin git@github.com:<name>/<Respo>(.git)

    相关文章

      网友评论

          本文标题:Git管理版本

          本文链接:https://www.haomeiwen.com/subject/pwofhxtx.html