方法一
参考文档: sudo rosdep init 出现 ERROR: cannot download default sources list from:
本质是把要下载的文件全部下载到本地,然后修改相应的URL。
-
把 https://github.com/ros/rosdistro 的配置文件下载到本地
git clone https://github.com/ros/rosdistro 这里下载到/home/uestc/目录下。 -
修改 /etc/ros/rosdep/sources.list.d/20-default.list 文件,
- 如果在第一步sudo rosdep init 没有生成20-default.list文件,那么可以自己手动在/home/uestc下:
touch 20-default.list - 打开这个文件:写入以下内容,请注意,路径必须和第1步中你下载的rosdistro 里的文件路径对应。
- 如果在第一步sudo rosdep init 没有生成20-default.list文件,那么可以自己手动在/home/uestc下:
yaml file:///home/xxx/rosdistro/rosdep/osx-homebrew.yaml osx
# generic
yaml file:///home/xxx/rosdistro/rosdep/base.yaml
yaml file:///home/xxx/rosdistro/rosdep/python.yaml
yaml file:///home/xxx/rosdistro/rosdep/ruby.yaml
gbpdistro file:///home/xxx/rosdistro/releases/fuerte.yaml fuerte