<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">When using regular expressions that
      include the \ character (and perhaps others) they need to be in
      single quotes, not double quotes.</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Also, the dates of the form  Feb 8
      10:11:54" often have a leading space on the day, so that your
      regex really needs to be '^\w+\s+\d+' to match both</div>
    <div class="moz-cite-prefix">Feb  9 10:11:54</div>
    <div class="moz-cite-prefix">Feb 19 10:11:54</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Not sure if that was your case, but it
      is a safer regex to cover such cases.</div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">I cant speak to why the space gets
      eaten in your '8 09:55:54 CST: ' example.<br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">Evan.<br>
    </div>
    <div class="moz-cite-prefix"><br>
    </div>
    <div class="moz-cite-prefix">On 2/8/19 8:18 AM, N. Max Pierson
      wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAD69L83AXp2jKj-nujtRbOgW0bYJRuR3pKVAvqj3ypjBD4c+xA@mail.gmail.com">
      <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
      <div dir="ltr">
        <div dir="ltr">
          <div dir="ltr">
            <div dir="ltr">
              <div dir="ltr">
                <div dir="ltr">
                  <div dir="ltr">
                    <div dir="ltr">
                      <div dir="ltr">Hi List,
                        <div><br>
                        </div>
                        <div>I am having some weird issues with rewrite
                          regex that I cannot explain. I am simply
                          trying to filter out the first part of the
                          message which has the date in this format.</div>
                        <div><br>
                        </div>
                        <div>Feb 8 09:13:32 CST:  (there is one space at
                          the end)<br>
                        </div>
                        <div><br>
                        </div>
                        <div> When I use the following syntax, it
                          doesn't match as expected.<br>
                        </div>
                        <div><br>
                        </div>
                        <div>^\w+\s\d+\s\d+:\d+:\d+\s\w+:\s<br>
                        </div>
                        <div><br>
                        </div>
                        <div>I know this is the correct pattern because
                          it works just fine on <a
                            href="http://www.regexpal.com"
                            moz-do-not-send="true">www.regexpal.com</a>.
                          I did some further testing and I have narrowed
                          it down to the below ...</div>
                        <div><br>
                        </div>
                        <div>^\w+</div>
                        <div>8 09:55:54 CST:  (this seemed to also
                          remove the space behind the month)</div>
                        <div><br>
                        </div>
                        <div>^\w+\s</div>
                        <div>8 09:59:37 CST:  (notice this is the exact
                          same as the above without the beginning space)<br>
                        </div>
                        <div><br>
                        </div>
                        <div>^\w+\s\d+</div>
                        <div>Feb 8 10:07:04 CST:  (doesn't match
                          anything as though the space between Feb and 8
                          isn't there)<br>
                        </div>
                        <div><br>
                        </div>
                        <div>^\w+\d+<br>
                        </div>
                        <div>Feb 8 10:11:54 CST:  (again doesn't match
                          anything as though there is a space between
                          Feb and 8)<br>
                        </div>
                        <div><br>
                        </div>
                        <div>So it seems to be something either with \w
                          word class or the + quantifier and it somehow
                          eats the space behind it possibly?? I am
                          running 3.19.1 on Centos 7.</div>
                        <div><br>
                        </div>
                        <div>Can anyone test this to confirm it isn't
                          just local to my install for whatever reason?</div>
                        <div><br>
                        </div>
                        <div>Regards,</div>
                        <div>Max</div>
                        <div><br>
                        </div>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>