fatal: ‘origin‘ does not appear to be a git repository
1. Go编译报错信息
E:\work\hqsource\stock\quote_sh_l2_parser>go build
go: xxxxxxx/yyyyyyyy/quote_lib@v0.3.115-0.20220302053425-232076327f09: invalid version: git ls-remote -q origin in C:\Go\repository\pkg\mod\cache\vcs\87198654213a7c861ce67251dbddf3f94fb383755ea8e89812eb7f12fc9c666e: exit status 128:fatal: 'origin' does not appear to be a git repositoryfatal: Could not read from remote repository.Please make sure you have the correct access rightsand the repository exists.
go编译时,git需要拉取对应的依赖库,拉取依赖库时,会先去GOPATH路径下的缓存去查找,如果缓存不正确,就有可能导致莫名其妙的问题。上面问题关键在这里
invalid version: git ls-remote -q origin in C:\Go\repository\pkg\mod\cache\vcs\87198654213a7c861ce67251dbddf3f94fb383755ea8e89812eb7f12fc9c666e
2. 解决方案
删除go同步依赖库的缓存,很多时候可能由于缓存有问题,造成了莫名其妙的错误,就类似于Java项目的maven时,依赖库没有正确下载,后续因为缓存库引入有问题,需要重新清理一下缓存才能正确编译和使用。
现在我们找到上面的文件夹,然后删除此文件夹。文件的路劲根据提示自己确认。我的需要删除的文件夹如下:
C:\Go\repository\pkg\mod\cache\vcs\87198654213a7c861ce67251dbddf3f94fb383755ea8e89812eb7f12fc9c666e
fatal: ‘origin‘ does not appear to be a git repository相关推荐
- 执行git命令时出现fatal: ‘origin‘ does not appear to be a git repository错误
执行git命令时出现fatal: 'origin' does not appear to be a git repository错误 在执行git pull origin master时出现: fat ...
- 将本地已经存在的代码跟github上新建的仓库建立关联,解决“fatal: 'origin' does not appear to be a git repository...”
我想将本地已经存在的代码跟github上新建的仓库建立关联,步骤如下: 进入本地目录,初始化本地仓库 1.进入本地目录,初始化本地仓库:git init 2.将文件添加到仓库:git add . 3. ...
- fatal: ‘origin‘ does not appear to be a git repository fatal: Could not read from remote repository.
fatal: 'origin' does not appear to be a git repository fatal: Could not read from remote repository. ...
- 解决“fatal: 'origin' does not appear to be a git repository...”
当使用Git进行代码push提交时,出现报错信息"fatal: 'origin' does not appear to be a git repository...", $ git ...
- 详解git pull命令和使用过程中遇到的常见问题:fatal: ‘origin‘ does not appear to be a git repository
使用git pull同步远程代码 使用git管理测试相关代码时,因为测试代码本身量级不大,所以很少使用分支,默认都使用master(主分支),当我们想要从远程origin(origin是远程仓remo ...
- Git本地仓库提交代码到远程仓库出现报错:fatal: ‘origin‘ does not appear to be a git repository fatal: Could not read fr
Git本地仓库提交代码到远程仓库出现报错:fatal: 'origin' does not appear to be a git repository fatal: Could not read fr ...
- git-报错总结-fatal: 'origin' does not appear to be a git repository...
1.在push时候报错,'origin' does not appear to be a git repository- 但是我的库是有的,检查分支也能检查到分支,就是push时候报错.可能两种原因, ...
- 解决“fatal: ‘origin‘ does not appear to be a git repository...”
当使用Git进行代码push提交时,出现报错信息"fatal: 'origin' does not appear to be a git repository...", $ git ...
- git报错:‘origin‘does not appear to be a git repository的解决方法
文章目录 #事故现场 #解决方法 #事故现场 git push origin master时报错: fatal: 'origin' does not appear to be a git reposi ...
最新文章
- 教育部发文35所高校新增AI本科专业!想回去重新高考
- RESTful API接口文档规范小坑
- 安卓学习笔记16:常用控件 - 标签
- poj 1155 TELE
- 吝啬的国度 ---用vector 来构图
- zTree保持展开单一路径之简易实现
- 【2019杭电多校第二场1005 = HDU6595】Everything Is Generated In Equal Probability(期望-递推)
- 7216:Minecraft题解
- 程序员的自我修养之数学基础10:超定方程的求解
- 参数检验和非参数检验的区别
- 12306火车票查询订票
- Windows CE SDHC驱动简析(1)-驱动架构(基于WinCE5.0 SMDK2410 BSP的SDHC驱动)
- Python之校庆代码
- Lsyncd:负载均衡之后,服务器的文件双向同步
- 不等距双杆模型_对磁场中双杆模型问题的解析
- Android中基于心知天气API获取天气信息
- 后台管理系统,前端框架
- <塞梅普雷斯 如是说> 第二部 0.序
- Population and carrying capacity 的第二阶段 :Crowding affects lifetime.
- android 闹钟不响,为什么我写的Android闹钟到时间时却不会响
热门文章
- 图像风格迁移cvpr2020_CVPR 2020 论文大盘点-文本图像篇
- 计算机桌面没有打字,电脑输入法不见了怎么办
- 仿商城商品生成分享海报图片和识别图中二维码并跳转商品详情页
- Matlab建模—回归拟合(ployfit与regress使用)
- Hadoop-1-大数据概述
- phpcmsV9 全站搜索功能如何实现
- Elastix 设置呼叫转移
- 派森学python_派森个人学习笔记------2020.09.06
- 火了,新东方年会吐槽视频《释放自我》:累死累活干不过写PPT的
- 计算机开机硬件检查,开机bios检测硬件信息方法