ARTICLE DETAIL

资讯详情

深耕网站建设与运营推广的一线实战洞察。

15、Git 文件管理全攻略

15、Git 文件管理全攻略

Git 文件管理全攻略

1. 基础配置

在使用 Git 时,我们可能需要进行一些配置操作。以下是一些常见的配置命令:
-设置默认编辑器:可以通过执行以下命令来设置默认编辑器,例如将其设置为vi

ocs@ubuntu:~/ocs$ git config --global core.editor vi
  • 查看当前配置设置:使用git config --list命令可以查看当前的配置信息:
ocs@ubuntu:~/ocs$ git config --list user.name=Bo Rothwell user.email=bo@onecoursesource.com core.editor=editor_name core.repositoryformatversion=0 core.filemode=true core.bare=false core.logallrefupdates=true remote.origin.url=https://gitlab.com/borothwell/ocs.git remote.origin.fetch=+refs/heads/*:refs/remotes/origin/* branch.master.remote=origin branch.master.merge=refs/heads/master
返回列表