Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/fishros/install
Browse files Browse the repository at this point in the history
  • Loading branch information
fishros committed May 24, 2024
2 parents fc71863 + b91b48d commit c28118f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion tools/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -1214,7 +1214,7 @@ def getArch():

@staticmethod
def search_package(name,pattern,replace1="",replace2=""):
result = CmdTask("sudo apt-cache search {} ".format(name),20).run()
result = CmdTask("sudo apt search {} ".format(name),20).run()
if result[0]!=0:
PrintUtils.print_error("搜索不到任何{}相关的包".format(name))
return None
Expand Down
12 changes: 6 additions & 6 deletions tools/tool_install_ros.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,9 +243,9 @@ def add_source(self):
PrintUtils.print_success("恭喜,成功添加ROS源,接下来可以使用apt安装ROS或者使用[1]一键安装ROS安装!")
return

#add source2
PrintUtils.print_warn("换源后更新失败,第三次开始切换源,尝试更换ROS2源为ROS2官方源!")
mirrors = self.get_mirror_by_code(osversion.get_codename(),arch=arch,first_choose="packages.ros")

PrintUtils.print_warn("换源后更新失败,第三次开始切换源,尝试使用https-ROS官方源~!")
mirrors = self.get_mirror_by_code(osversion.get_codename(),arch=arch,first_choose="https.packages.ros")
PrintUtils.print_info("根据您的系统,为您推荐安装源为{}".format(mirrors))
source_data = ''
for mirror in mirrors:
Expand All @@ -257,8 +257,9 @@ def add_source(self):
PrintUtils.print_success("恭喜,成功添加ROS源,接下来可以使用apt安装ROS或者使用[1]一键安装ROS安装!")
return

PrintUtils.print_warn("换源后更新失败,第四次开始切换源,尝试使用https-ROS2官方源~!")
mirrors = self.get_mirror_by_code(osversion.get_codename(),arch=arch,first_choose="https.packages.ros")
#add source2
PrintUtils.print_warn("换源后更新失败,第四次开始切换源,尝试更换ROS源为http-ROS官方源!")
mirrors = self.get_mirror_by_code(osversion.get_codename(),arch=arch,first_choose="packages.ros")
PrintUtils.print_info("根据您的系统,为您推荐安装源为{}".format(mirrors))
source_data = ''
for mirror in mirrors:
Expand All @@ -274,7 +275,6 @@ def add_source(self):
if not AptUtils.checkapt(): PrintUtils.print_error("四次换源后都失败了,请及时联系小鱼获取解决方案并处理!")



def support_install(self):
# check support
if (osversion.get_codename() not in ros_dist_dic.keys()) and (osversion.get_codename() not in ros2_dist_dic.keys()):
Expand Down
2 changes: 1 addition & 1 deletion tools/tool_install_wechat.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ def install_wechat(self):
if code==4:
try:
CmdTask("sudo apt remove wechat-linux-spark -y",os_command=True).run()
CmdTask("sudo apt remove ukylin-wechat -y",os_command=True).run()
CmdTask("sudo apt remove wechat-* -y",os_command=True).run()
CmdTask("sudo docker stop wechat",os_command=True).run()
CmdTask("sudo docker rm wechat",os_command=True).run()
CmdTask("sudo docker image rm bestwu/wechat",os_command=True).run()
Expand Down

0 comments on commit c28118f

Please sign in to comment.