title: regex: match multiple lines until a line contains
body: <p>I have the following string:</p>
  
  <pre><code>foo.a = [10
  20
  30
  40];
  
  foo.b = 'foobar';
  </code></pre>
  
  <p>I am using the <a href="https://regex101.com/r/lR9kN2/1" rel="noreferrer"><code>foo\.[ab]\s*=</code> regex</a>.</p>
  
  <p>I try to match all the lines that follow until a line contains a certain character.</p>
  
  <p>The first match should cover everything except of the last line, because that line contains an equal sign. I tried a lot of things with (negative) lookahead, but I can't figure it out.</p>