Skip to content

[Bug] Shell脚本语法错误修复 #1285

@vipmc838

Description

@vipmc838

Verify steps

  • 我已经在 Issue Tracker 中找过我要提出的问题 I have searched on the issue tracker for a related issue.
  • 我已经使用公测版本测试过,问题依旧存在 I have tested using the test mod, and the issue still exists.
  • 我已经仔细看过 常见问题 并无法自行解决问题

Description

Shell脚本语法错误修复

-----------------------------------------------
欢迎使用ShellCrash!            版本:1.9.4release
Mihomo服务正在运行(混合模式),已设置开机启动!
当前内存占用:64.69 MB,已运行:00小时01分50秒
TG频道:https://t.me/ShellClash
-----------------------------------------------
发现内核配置文件: /tmp/config.yaml 
是否加载为meta的配置文件?(1/0) > 1
配置文件加载完成! 
 1 启动/重启服务
 2 功能设置
 3 停止服务
 4 启动设置
 5 设置自动任务
 6 管理配置文件
 7 访问与控制
 8 工具与优化
 9 更新与支持
-----------------------------------------------
 0 退出脚本
请输入对应数字 > 1
-----------------------------------------------
/etc/ShellCrash/starts/fw_stop.sh: 24: [: unexpected operator   # 这里提示语法错误
服务已启动!                       
请使用 http://192.168.1.222:9000/ui 管理内置规则

修复方法

sed -i '24s/==/=/' /etc/ShellCrash/starts/fw_getlanip.sh
-----------------------------------------------
欢迎使用ShellCrash!            版本:1.9.4release
Mihomo服务正在运行(混合模式),已设置开机启动!
当前内存占用:52.38 MB,已运行:00小时06分10秒
TG频道:https://t.me/ShellClash
-----------------------------------------------
 1 启动/重启服务
 2 功能设置
 3 停止服务
 4 启动设置
 5 设置自动任务
 6 管理配置文件
 7 访问与控制
 8 工具与优化
 9 更新与支持
-----------------------------------------------
 0 退出脚本
请输入对应数字 > 1
3-----------------------------------------------
服务已启动!                       
请使用 http://192.168.1.222:9000/ui 管理内置规则

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions