Dan*_*l99 6 git https bitbucket
从 BitBucket 克隆。
我的 Git 设置正常,但在克隆时出现此错误。https。我拥有 BitBucket 网站的访问权限,可以查看所有项目,包括我想要克隆的项目。
我访问过该网站,https不再支持。我应该如何克隆?
更新:我需要设置应用程序密码... brb
终端:
me@me:~$ git --version
git version 2.25.1
me@me:~$ git config --list
user.name=me
user.email=me@job.com
me@me:~$ git clone https://me@bitbucket.org/foo/bar.git
Cloning into 'bar'...
Password for 'https://me@bitbucket.org':
remote: Bitbucket Cloud recently stopped supporting account passwords for Git authentication.
remote: See our community post for more details: https://atlassian.community/t5/x/x/ba-p/1948231
remote: App passwords are recommended for most use cases and can be created in your Personal settings:
remote: https://bitbucket.org/account/settings/app-passwords/
fatal: Authentication failed for 'https://bitbucket.org/foo/bar.git/'
me@me:~$ git clone git@bitbucket.org:foo/bar.git
Cloning into 'bar'...
The authenticity of host 'bitbucket.org (104.192.141.1)' can't be established.
RSA key fingerprint is SHA256:BLAH.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added 'bitbucket.org,104.192.141.1' (RSA) to the list of known hosts.
git@bitbucket.org: Permission denied (publickey).
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Run Code Online (Sandbox Code Playgroud)
解决方案
您需要设置一个应用程序密码。
在 Bitbucket 上,请按照以下6 个步骤操作。
然后,在终端中:
git clone https://USERNAME:APP_PASSWORD@bitbucket.org/username/reposlug.git
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
18087 次 |
| 最近记录: |