$ perl -le 'print "bar\n" =~ /^bar$/ ? "ok" : "not ok"' ok