- c - 在位数组中找到第一个零
- linux - Unix 显示有关匹配两种模式之一的文件的信息
- 正则表达式替换多个文件
- linux - 隐藏来自 xtrace 的命令
我开设了一个新的 GitHub 帐户,以将我的业务存储库与个人存储库分开。
现在,我 git init
我的本地存储库和 git add remote origin <the repository HTTPS URL>
我尝试推送,它似乎总是使用我的原始帐户的凭据,而不是提示我输入新帐户的凭据。
我尝试使用 URL 格式
https://<username>:<password>@github.com/<username>/<repository.git>
但这似乎无济于事:我仍然收到错误消息,指出凭据对于原始帐户用户名无效。
我如何使用多组凭据登录,或者我如何以某种方式重置原始凭据以在推送时强制提示密码?
我现在设法推送的唯一方法是指定 username:password@github.com/
在 URL 中 git push
命令。
最佳答案
git config --global credential.helper cache
... 这告诉 git 将您的密码在内存中缓存(默认情况下)15 分钟。你可以set a longer timeout与:
git config --global credential.helper "cache --timeout=3600"
更有用的链接:
Using the .netrc file The .netrc file is a mechanism that allows you to specify which credentials to use for which server.
This method allows you to avoid entering a username and password every time you push to or pull from Git, but your Git password is stored in plain text.
您可以使用以下命令存储您的凭据
git config credential.helper store
git push http://example.com/repo.git
# Now type username and password and it should be saved by git.
关于git - 多账号命令行登录GitHub,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34731832/
我无法理解 hl7 中关键概念之间的差异。 有人可以解释一下以下内容的差异吗: 什么是访问?访问次数通常位于哪里?什么是遭遇数?遭遇号码通常位于哪里?hl7中的遭遇等级和访问等级有什么区别?帐号是多少
Steam平台限时半价购买《绝地求生》账号 进入活动先登陆 然后加入购物车下单就行了 经常洗我绝地求生的可以去买一个 挺划算的 活动地址:http://t.cn/RBgS3tN 手机扫码
我正在开发一个可以调用互联网电话的 Android 应用程序。我让一切正常,从 SIP 服务器注册和调用电话,更新实时状态等。但是我用于应用程序的 SIP 帐户已在代码中设置。这不是我想要的。 在an
Substrate Collectables Workshop在某些时候建议开发者链为 Alice 提供预注资金的帐户。 Let's go into the Transfer app, and mak
我正在尝试向我的应用程序添加登录系统,使用 meteor accounts-facebook 效果很好,但我不知道为什么使用 accounts-password 似乎不起作用。这是出现的消息。 **C
废话不多说了,直接给大家贴实现此功能的正则表达式代码了,具体代码如下所示: ?
我是一名优秀的程序员,十分优秀!