git入门手册

安装->配置->帮助

安装:sudo apt install git-all

配置:git config

1、用户名和邮箱

git config --global git config --global user.name "Leo Musk"

git config --global user.email [email protected]

2、编辑器

git config --global core.editor nano

3、帮助

git help <cmd>

常用命令分类

环境配置:config

仓库初始化:init        clone        submodule

代码抽取:checkout

暂存区处理:add        mv           rm        clean        gc        diff        status

补丁管理:format-patch        am        apply        cherry-pick

提交:commit        gui

分支管理:branch        merge

查看检索:log        show        reflog        notes        grep        whatchanged

远程仓库访问:remote        fetch        pull        request-pull        push

代码整理:tag        rebase        revert        reset


猜你喜欢

转载自blog.csdn.net/Leo_ZN_0/article/details/79996497