我是一名分公司职员,已经将我现有的回购文件上传到我公司中央办公室的ftp服务器上。中央办公室正在使用微软的ftp服务器。我无法在服务器上安装任何东西,只能使用支持活动模式ftp的真正ftp客户端连接/浏览到ftp服务器。
我尝试使用以下命令行进行克隆:
git clone ftp://companyDomain\username@ftp.company.com/project.repo/.git
git clone ftp://username@company.com@ftp.company.com/project.repo/.git
git clone ftp://username%40company.com@ftp.company.com/project.repo/.git
git clone ftp://username:password@ftp.company.com/project.repo/.git我得到以下错误消息:
错误:连接到
ftp.company.com:21失败;访问ftp://companyDomain\username@ftp.company.com/project.repo/.git/info/refs失败时没有错误: HTTP请求失败
当输入上述命令时,会立即提示输入密码。我输入密码,一些时间的推移,然后我收到上述错误信息。
要完全清楚的是,我并不是想把源代码的头版本推到FTP服务器上进行部署,所以像git-ftp、https://github.com/resmo/git-ftp这样的东西根本帮不了我。我想要做的是让我的回购在ftp服务器上,并且我的团队中的每个人都能够在ftp服务器上推动/获取对回购的更改。
git支持主动FTP吗?到底怎么回事?
谢谢,克里斯
发布于 2012-10-23 15:11:45
他们是否使用默认的FTP端口?如果他们不这样做,你需要这样声明:
git clone ftp://username:password@ftp.company.com:PORTHERE/project.repo/.git发布于 2011-10-27 17:18:12
试一试
git clone ftp://username:password@ftp.company.com/project.repo/.git发布于 2017-09-02 07:26:28
我也尝试了所有的FTP例子,这里,没有一个是有效的。由于我的服务器pc是一台linux机器,所以我在它上安装了git,然后可以使用:
git clone username:servername:/folder1/folder2/repoFolder.git然后你会被问到密码。如果服务器上没有安装git,您将得到:
sh: git-upload-pack: not found
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.https://stackoverflow.com/questions/7919736
复制相似问题