运行环境
- IDEA版本:2020.2.3
- Windows 10
- git 版本:2.29.2
问题描述:
每次push到github时都提示登录,如下图:
然而,用命令行push是成功的(此方法适用的前提是能从命令行登录)。
IDEA的File|Settings|Version Control|GitHub
的配置是已经授权成功了:
试了下使用Token和Login Via GitHub都是可以正常授权的。
解决方法
看了下IDEA命令行,credential.helper
没有配置
git -c credential.helper= -c core.quotepath=false -c log.showSignature=false push --progress --porcelain origin refs/heads/master:master
在File|Settings|Version Control|Git
中勾选Use credential helper
即可解决这个问题。