what is wrong with my unix script

后端 未结 5 1023
温柔的废话
温柔的废话 2021-01-29 03:17
#!/bin/bash

while echo -n \"Player\'s name?\"
    read name
    [ $name != \'ZZZ\' ]
do
    searchresult=$(grep [$name] playername)
    if [ $searchresult = 0 ]
    the         


        
5条回答
  •  一整个雨季
    2021-01-29 03:31

    Use -eq instead = in your if statement in your script or use -z option to check empty string.

提交回复
热议问题