重要的 Git 命令和教程

如何获取 Git 命令的帮助

git 帮助 [-a|–all|-i|–info|-m|–man|-w|–web] [COMMAND]

例子: git 动动 git

它将启动浏览器并显示 HTML 格式。

建立本地存储库并进行初始主动:

cd my_project
git init
git add *
git commit -m "My initial commit message"
git remote add origin git@example.com:my_project.git
git push -u origin master

签出存储库

git clone git://github.com/schacon/grit.git

要将更改提交到本地存储库,只需添加即可,而不是提交。如果您想将本地分支/更改推送到远程存储库,只需执行下面的推送命令。

git add --all

git commit --all

git push

推送到存储库命令

git push <remote> <local branch name>:<remote branch to push into>
git push [--all | --mirror | --tags] [--follow-tags] [-n | --dry-run] [--receive-pack=]
           [--repo=] [-f | --force] [--prune] [-v | --verbose] [-u | --set-upstream]
           [--force-with-lease[=[:]]]
           [--no-verify] [ […]]

更多命令可以在以下链接中找到。

包含 20 个使用日 Git

https://www.kernel.org/pub/software/scm/git/docs/everyday.html

很好的 Git 教程

教程1先电影-http://git-scm.com/docs/gittutorial

– 创建的教程 2 秒 http://git-scm.com/docs/gittutorial-2.html

进一步教程 – http://www.vogella.com/tutorials/Git/article.html#firstgit_repostatus

2条回应“重要的Git命令和教程”

  1. 我想感谢您的精彩阅读!
    我绝对喜欢它的每一点。我有
    您添加书签以查看您发布的新内容...

  2. 哇,这一段​​好舒服,我的小弟
    姐姐正在分析这些事情,
    因此我要通知她。

发表回复