-
Notifications
You must be signed in to change notification settings - Fork 416
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
linux 使用 os-check 巡检时报错check_linux.sh: line 41: -: -: syntax error: operand expected (error token is "-") #11
Comments
感谢提醒,我加了个数字判断。你可以试试。
|
加了判断没有生效,我加了个判断,你可以参考下
|
value=${2:-0}if [[ 试了下 这个 可以解决那个问题 |
后面又重新看了下,这个还要考虑下有小数的情况,我这里又改了一版,你们试试。 Ansible-roles/os-check/files/check_linux.sh Lines 41 to 42 in 24a53f6
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
当我运行os-check 巡检后,生成的html文件报错
如图所示
具体报错:
check_linux.sh: line 41: -: -: syntax error: operand expected (error token is "-")
check_linux.sh: line 43: -: -: syntax error: operand expected (error token is "-")
操作系统
CentOS Linux release 7.9.2009 (Core)
The text was updated successfully, but these errors were encountered: