git 克隆项目到一个非空目录

来源: 老季博客
日期: 2018-3-13
作者: 腾讯云/服务器VPS推荐评测/Vultr
阅读数: 57

1. 进入非空目录,假设是 /laoji.org

2.

 git clone --no-checkout https://git.oschina.net/NextApp/platform.git tmp

3. #将 tmp 目录下的 .git 目录移到当前目录

mv tmp/.git .

4.

rmdir tmp

5.

git reset --hard HEAD

 

链接到文章: https://jiloc.com/43557.html

发表回复

您的电子邮箱地址不会被公开。 必填项已用*标注