idea 配置 git 与 idea 登录不上git 问题 您所在的位置:网站首页 内网139邮箱怎么登录不上 idea 配置 git 与 idea 登录不上git 问题

idea 配置 git 与 idea 登录不上git 问题

2023-12-16 23:33| 来源: 网络整理| 查看: 265

1.安装git

Git 的 msysGit 官网下载:https://git-scm.com/ Git 客户端 TortoiseGit 官网下载:http://download.tortoisegit.org/tgit/

2.配置git

在这里插入图片描述

3.登录git

地址:https://github.com/ 在这里插入图片描述 本地代码分享到git 在这里插入图片描述 导出到idea 在这里插入图片描述 在这里插入图片描述

历史版本查看 在这里插入图片描述

idea 登录不上git 问题

incalid authentication data.connection refused:connect 打开hosts文件:C:\Windows\System32\drivers\etc\hosts 在这里插入图片描述 登录成功后 上传至github

在这里插入图片描述 结果保错:

Can’t finish GitHub sharing process Successfully created project ‘springboot’ on GitHub, but initial commit failed: *** Please tell me who you are.

Run

git config --global user.email “[email protected]” git config --global user.name “Your Name”

to set your account’s default identity. Omit --global to set the identity only in this repository.

fatal: empty ident name (for ) not allowed during executing git -c core.quotepath=false commit -m “Initial commit” –

打开GitHub,查看自己项目发现只创建了一个空的仓库,点击仓库名,进入仓库,

点击setting,拖动到最下面,点击delete this repository,输入仓库名称,点删除。

4、打开git安装目录,找到git bash,双击运行,执行命令

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

git config --global user.name “Your Name” 上面的方法配置的是全局的用户名和邮箱!就是说如果没有单独为项目配置,那提交的所有项目全部都是这个名字和邮箱!不管是公司项目还是github,还是码云!

单独为项目配置的方法(全局和单独配置都存在的时候会默认使用项目单独配置的):

1.打开项目所在目录,找到隐藏的.git文件夹。注意这个文件夹是隐藏的,显示隐藏出来就行。

2.打开文件夹里的config文件,推荐用nodepad++打开。

3.添加这三行到文件:

[user] name = XXX(自己的名称) email = XXXX(邮箱) 当然也可以通过命令行的方式,只需要在 .git 文件夹下。 例如执行如下命令:

git config user.name “xxxxx”



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有