linux - compare empty string cshell -


i facing problem compare empty string detected grep file. want detect empty file searched first if condition, file search empty, cannot go if ($vg == "") condition echo output , execute cp condition.

code use find file:

set lvg =`find ${lward}/netlists/verilog/ -name "${subblock}.v"` 

below code:

foreach vg (${lvg})  if ($vg == "")    echo "${subblock}.vg file not found"  else if (${vg} =~ "*/${subblock}.vg")    cp -r "$vg" ./primetime/design/verilog/${subblock}.v  endif  end 


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -