我已经调试了这一行一段时间了,我确信它很简单:
370 #Loop through the file looking for any non-required lines
371 { while read myline;do
372 if [[ $myline != "WARN0; 300086; prod_file_stat; Can't find EBCDIC product for PRODUCT_FILE_STATUS;for ASCII 10288" && $myline != "WARN0; 300086; prod_file_stat; Can't find EBCDIC product for PRODUCT_FILE_STATUS;for ASCII 10284" ]]; then
373 echo "ERR: file contains unacceptable errors or warnings! Please double check!"
374 err=1
375 fi
我明白了:
check[50]: syntax error at line 373 : `10284" ]]; then
echo "ERR:' unexpected
它与字符串中的空格有关,还是红鲱鱼?它是一个KSH脚本。