If we clone the Git project to a non-empty directory , an error message will be prompted:
fatal: destination path '.' already exists and is not an empty directory.
The solution is:
1. Enter a non-empty directory, assuming /workdir/proj1
2. git clone --no-checkout https://git.oschina.NET/NextApp/platform.git tmp
3. mv tmp/.git . #Move the .git directory in the tmp directory to the current directory
4. rmdir tmp
5. git reset --hard HEAD
Then you can perform various normal operations.
Reprinted from: http://www.oschina .Net /question/54100_167919?sort=time