Solve code issue - string identity testing
- by kovibb
Please for help with shell script. I really dont understand where is problem. Where I write to the Input variable for example /home/Kovi/Deskop/netlist.exe I still get true answer but the extension "exe" is not "scs". I also try "==" but it didnt working. Please some advice. Thank you very much.
echo -n "Insert Entire Path (with file name and it's extension) of Input Netlist > "
read Input
if [ "${Input##*.}"="scs" ];
then echo "Patch verification is succesful.;
else echo "Patch verification is failed, script was aborted. File dont exist or is empty or unreadable or is not spectre netlist."
error_exit;
fi