Save count of lines from file $file matching with pattern $filter and not matching with pattern $nfilter in variable 'totalLineCnt'
totalLineCnt=$(cat "$file" | grep "$filter" | grep -v "$nfilter" | wc -l | grep -o '^[0-9]\+');