title: Perl multiline regex in windows
body: <p>I'm stuck with this scenario, I have this <a href="https://regex101.com/r/z0WoN0/1" rel="nofollow noreferrer">regex</a></p>
  <p>*Input added here for clarity:</p>
  <pre><code>181221533;MG;3;1476729;&lt;vars&gt;  &lt;vint&gt;    &lt;name&gt;mtest&lt;/name&gt; &lt;storedPrecedure&gt;f_sc_mtest&lt;/SP&gt;    &lt;base&gt;M_data&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeMS&gt;17&lt;/timeMS&gt;    &lt;ttidr&gt;abc&lt;/ttidr&gt;  &lt;base&gt;S&lt;/base&gt;    &lt;valor&gt;0&lt;/valor&gt;  &lt;/vint&gt;  &lt;/vars&gt;;889;6;85;112;01/01/2019;29/05/2019 17:17:48
  182652972;MG;6314429;740484;&lt;vars&gt;  &lt;vint&gt;    &lt;name&gt;mtest&lt;/name&gt;    &lt;sP&gt;f_sc_mtest&lt;/sP&gt; &lt;base&gt;sscy&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeMS&gt;16&lt;/timeMS&gt;    &lt;ttidr&gt;abc&lt;/Idtype&gt;    &lt;base&gt;S&lt;/base&gt;    &lt;valor&gt;4&lt;/valor&gt;  &lt;/vint&gt;&lt;/vars&gt;;-1;8;57217;57228;01/01/2019;06/06/2019 22:20:48
  182652984;ModeloSP;6314429;740484;&lt;vars&gt;  &lt;vint&gt;     &lt;name&gt;tc_p_act&lt;/name&gt;    &lt;sP&gt;rndom_name&lt;/sP&gt;    &lt;base&gt;sscyo&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeMS&gt;0&lt;/timeMS&gt;    &lt;Idtype&gt;XYZ&lt;/Idtype&gt;    &lt;base&gt;O&lt;/base&gt;  &lt;/vint&gt;
  &lt;/vars&gt;;0;;0;41;01/01/2019;06/06/2019 22:31:22
  
  182652988;ModeloSP;6314429;740484;&lt;vars&gt;  &lt;vint&gt;     &lt;name&gt;tc_p_act&lt;/name&gt;    &lt;sP&gt;rndom_name&lt;/sP&gt;    &lt;base&gt;sscyo&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeProcess&gt;1&lt;/timeProcess&gt;    &lt;Idtype&gt;XYZ&lt;/Idtype&gt;    &lt;base&gt;O&lt;/base&gt;  &lt;/vint&gt;
  &lt;/vars&gt;;0;;0;85;01/01/2019;06/06/2019 22:37:36
  </code></pre>
  <p>And I want to implement this regex in perl with multiline support because as you can see in the sample, there are line breaks in records and this regex searchs 'incomplete' lines (and the extra line) and fixes them (one record/line should end with a datetime)</p>
  <p>this is what I'm attempting with perl:</p>
  <pre><code>perl.exe -0777 -i -pe &quot;s/(?m)^(.*)(&gt;)([\n]+)(&lt;)(.*)([\n]+)(\s*)$/$1$2    $4$5/igs&quot; &quot;sample.txt&quot;
  </code></pre>
  <p>And doesn't seem to work, I keep getting the same text file. I'm using perl inside a portable GIT installation (v5.34.0)</p>
  <p>Is there something I'm missing?</p>
  <p>edit: This is how the output should look like:</p>
  <pre><code>181221533;MG;3;1476729;&lt;vars&gt;  &lt;vint&gt;    &lt;name&gt;mtest&lt;/name&gt; &lt;storedPrecedure&gt;f_sc_mtest&lt;/SP&gt;    &lt;base&gt;M_data&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeMS&gt;17&lt;/timeMS&gt;    &lt;ttidr&gt;abc&lt;/ttidr&gt;  &lt;base&gt;S&lt;/base&gt;    &lt;valor&gt;0&lt;/valor&gt;  &lt;/vint&gt;  &lt;/vars&gt;;889;6;85;112;01/01/2019;29/05/2019 17:17:48
  182652972;MG;6314429;740484;&lt;vars&gt;  &lt;vint&gt;    &lt;name&gt;mtest&lt;/name&gt;    &lt;sP&gt;f_sc_mtest&lt;/sP&gt; &lt;base&gt;sscy&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeMS&gt;16&lt;/timeMS&gt;    &lt;ttidr&gt;abc&lt;/Idtype&gt;    &lt;base&gt;S&lt;/base&gt;    &lt;valor&gt;4&lt;/valor&gt;  &lt;/vint&gt;&lt;/vars&gt;;-1;8;57217;57228;01/01/2019;06/06/2019 22:20:48
  182652984;ModeloSP;6314429;740484;&lt;vars&gt;  &lt;vint&gt;     &lt;name&gt;tc_p_act&lt;/name&gt;    &lt;sP&gt;rndom_name&lt;/sP&gt;    &lt;base&gt;sscyo&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeMS&gt;0&lt;/timeMS&gt;    &lt;Idtype&gt;XYZ&lt;/Idtype&gt;    &lt;base&gt;O&lt;/base&gt;  &lt;/vint&gt;    &lt;/vars&gt;;0;;0;41;01/01/2019;06/06/2019 22:31:22
  182652988;ModeloSP;6314429;740484;&lt;vars&gt;  &lt;vint&gt;     &lt;name&gt;tc_p_act&lt;/name&gt;    &lt;sP&gt;rndom_name&lt;/sP&gt;    &lt;base&gt;sscyo&lt;/base&gt;    &lt;dataType&gt;I&lt;/dataType&gt;    &lt;timeProcess&gt;1&lt;/timeProcess&gt;    &lt;Idtype&gt;XYZ&lt;/Idtype&gt;    &lt;base&gt;O&lt;/base&gt;  &lt;/vint&gt;    &lt;/vars&gt;;0;;0;85;01/01/2019;06/06/2019 22:37:36
  </code></pre>