Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/batch-file/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Git分支提交,我做错了什么_Git - Fatal编程技术网

Git分支提交,我做错了什么

Git分支提交,我做错了什么,git,Git,我想对一个公共git项目做一个小改动 所以我做了: git clone BLAH git checkout -b NEWBRANCH 对现有文件进行了更改,但没有 git commit -a -m "did stuff" 它给 fatal: Not a git repository (or any parent up to mount parent ) Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not s

我想对一个公共git项目做一个小改动

所以我做了:

git clone BLAH
git checkout -b NEWBRANCH
对现有文件进行了更改,但没有

git commit -a -m "did stuff"
它给

fatal: Not a git repository (or any parent up to mount parent )
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).

我错过了一个步骤还是什么?

git clone BLAH
在BLAH目录中创建了一个git repo。只需执行
cd BLAH
git clone BLAH
即可在BLAH目录中创建git repo。只需执行
cd BLAH

是否确实从git树中提交?是否从同一目录发出所有git命令?是否确实从git树中提交?是否从同一目录发出所有git命令?嗯,不完全是这样--创建的目录将取决于使用的URI。但这是显而易见的答案;)Gahghghg,我想我有,这就解决了。嗯,不完全是这样——创建的目录将取决于使用的URI。但这是显而易见的答案;)嘎嘎,我以为我有,这就解决了。