在同一台Windows 7计算机上使用Git和两个本地文件夹

在同一台Windows 7计算机上使用Git和两个本地文件夹,git,windows-7,Git,Windows 7,我试图在Windows7笔记本电脑上学习Git(Git版本1.9.4.msysgit.2) 我想创建一个source文件夹和一个code文件夹来练习 我可以使用git init创建主文件夹,并使用git add.和git commit-m“原始文件”添加测试文件 然后在code文件夹中,我使用git clone c:\source\git警告: You appear to have cloned an empty repository. 并调用文件夹(主文件夹)git add.和git com

我试图在Windows7笔记本电脑上学习Git(Git版本1.9.4.msysgit.2)

我想创建一个
source
文件夹和一个
code
文件夹来练习

我可以使用
git init
创建主文件夹,并使用
git add.
git commit-m“原始文件”
添加测试文件

然后在
code
文件夹中,我使用
git clone c:\source\
git警告:

You appear to have cloned an empty repository.
并调用文件夹(主文件夹)
git add.
git commit
在添加测试文件时工作正常。但是当我<代码> Git Pux到我认为是主存储库时,Git报告如下:

$ git push
fatal: 'c:source' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists. 

我正在查找有关如何克隆到远程存储库和从远程存储库克隆的参考资料,但我想先了解如何实现本地文件夹事务。是否可能,或者我的逻辑有什么缺陷?

如果您使用的是Git Bash(或其他POSIXy环境),您可能必须转义或引用这些反斜杠,例如:
Git clone c:\\source\\\
Git clone'c:\source\
。Git clone正在按我所述工作。我的问题是,我需要解决git push的
git错误。或者我可以将
从一个本地文件夹推送到另一个文件夹吗?或者我只是在狂吠?;-)从本地目录中的存储库推送到本地目录中的另一个存储库就可以了。我觉得奇怪的是,Git在推的时候提到了
c:source
(没有反斜杠)。此外,关于空存储库的警告也很奇怪。在“主”存储库中,
git status
git whatchanged
显示了什么?(顺便说一句,请停止调用目录和存储库“master”,因为它在Git中具有“特殊意义”。)请尝试路径名的msysgit版本:
Git clone/c/source