fix msys not supporting regex comparison