Title basically says it all, but I can't figure it out for the life of me and getting confused by bash regular expression matching. This is the if statement I have in my bash script, but it keeps matching the line ${new_user} instead of # ${new_user}. I basically want to match a "commented out" user.
if [[ $(<"foo.txt") =~ \#.*${new_user} ]]; then