gpt4 book ai didi

git - 带有登录凭据的 Bitbucket repo 克隆

转载 作者:行者123 更新时间:2023-12-03 15:36:16 27 4
gpt4 key购买 nike

我有一个到 bitbucket 的基本 git clone 命令,我必须在其中添加登录凭据,是否可以将登录凭据添加到 bitbucket git clone 命令?

https://myacc@bitbucket.org/myacc/app.git

像这样的东西?
https://myacc@bitbucket.org/myacc/app.git -Password "123"

最佳答案

你可以,与:

git clone https://user:password@bitbucket.org/myacc/app.git

但这会将您的凭据保存在 .git/config 中的原始 url 中。 .
为避免之后您可以更改原点 git remote set-url origin https://myacc@bitbucket.org/myacc/app.git

关于git - 带有登录凭据的 Bitbucket repo 克隆,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/52869520/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com