简体   繁体   English

使用https协议在Linux中克隆Git存储库

[英]Clone Git repository in Linux using https protocol

I am trying to clone a repository in Linux using this command: 我正在尝试使用以下命令在Linux中克隆存储库:

git clone username@https://host:port/repository.git

But I keep getting error. 但是我总是出错。

Can someone please tell me the correct command to clone a repository on linux using https? 有人可以告诉我使用https在Linux上克隆存储库的正确命令吗?

Please specify what errors or issues you're facing. 请指定您遇到的错误或问题。

You can try to simply clone from the https and enter your username and password on prompt 您可以尝试从https克隆并在提示时输入您的用户名和密码

git clone https://host/repository.git

Then again I strongly recommend switching to ssh if you're planning to use git often on the local machine 再一次,如果您打算在本地计算机上经常使用git,我强烈建议切换到ssh

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 强制 git 使用 https 协议克隆子模块 - Force git to clone submodules using https protocol 使用 GIT 将 TFS-GIT 存储库克隆到 GIT 存储库 (Linux) - Clone TFS-GIT repository to GIT repository (Linux) by using GIT 尝试使用git协议克隆存储库会导致https错误? - Trying to clone a repo using git protocol leads to https error? 无法在 git 协议下克隆任何存储库(使用 git clone git://) - Cannot clone any repository under git protocol (using git clone git://) 使用具有https凭证的GitPython克隆AWS CodeCommit git存储库 - Clone AWS CodeCommit git repository using GitPython with https credentials 无法使用 https 和 Z765553E6C7AC85A00AZ 链接9ACB8 克隆 Eclipse 中的 git 存储库 - Unable to clone git repository in Eclipse using https and SSH links Git克隆:libcurl中不支持或禁用协议https - Git clone: Protocol https not supported or disabled in libcurl 使用GIT命令将TFS-GIT存储库克隆到GIT存储库(Linux) - Clone TFS-GIT repository to GIT repository (Linux) by using GIT commands 为什么使用HTTPS时git clone失败,但使用git协议成功 - why git clone failed when using HTTPS but succeed using git protocol 通过https克隆最新版本的git存储库 - Clone the latest version of a git repository through https
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM