Thursday, 28 March 2019

Sample Shell scripts



To Check Folder :


if [ -d "/path/to/dir" ] 
then
    echo "Directory /path/to/dir exists." 
else
    echo "Error: Directory /path/to/dir does not exists."
fi



To Check WSDL :

Status = `curl -Is http://localhost:port/sampleservice?wsdl | head -n 1 | cut -d ' ' -f 2`

It will provide HTTP response code. 



No comments:

Post a Comment