Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

if has bash

string='Hi substring' #To check if string has "Mylong" substring do
if [[ $string == *"substring"* ]]; then
  echo "String has substring"
fi
 
PREVIOUS NEXT
Tagged: #bash
ADD COMMENT
Topic
Name
1+4 =