Home > Development Tools > git > What are the six commonly used commands in Git?

What are the six commonly used commands in Git?

Guanhui
Release: 2020-08-06 11:34:42
Original
9255 people have browsed it

What are the six commonly used commands in Git?

#What are the six commonly used commands in Git?

1. "git clone" to clone the code; 2. "git log" to view the log; 3. "git tag" to view the tag; 4. "git branch" to view the branch; 5. "git branch" -a" to view the remote branch; 6. "git pull" to pull.

Git clone

# 默认在当前目录下创建和版本库名相同的文件夹并下载版本到该文件夹下
$ git clone <远程仓库的网址>

# 指定本地仓库的目录
$ git clone <远程仓库的网址> <本地目录>

# -b 指定要克隆的分支,默认是master分支
$ git clone <远程仓库的网址> -b <分支名称> <本地目录>
Copy after login

Recommended tutorial: " Programming Video"

The above is the detailed content of What are the six commonly used commands in Git?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
git
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template