git pull代码时候出现,或者push代码无效
fatal: No remote repository specified. Please, specify either a URL or a
remote name from which new revisions should be fetched.
解决找到本地仓库项目里面的 .git文件夹,找到
config打开,修改里面内容为
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
precomposeunicode = false
[remote "origin"]
url = https://github.com/CrossLee/xxx.git
fetch = +refs/heads/*:refs/remotes/origin/*
pushurl = https://github.com/CrossLee/xxx.git
[branch "master"]
remote = origin
merge = refs/heads/master
把其中换成你项目的地址就可以了:
url = https://github.com/CrossLee/xxx.git
pushurl = https://github.com/CrossLee/xxx.git