title: Python regex to get everything until the first dot in a string
body: <pre><code>find = re.compile("^(.*)\..*")
  for l in lines:
      m = re.match(find, l)
      print m.group(1) 
  </code></pre>
  
  <p>I want to regex whatever in a string until the first dot.</p>
  
  <p>in <code>a@b.c</code>, I want <code>a@b</code><br>
  in <code>a@b.c.d</code>, I want <code>a@b</code><br>
  in <code>a@b.c.d.e</code>, I want <code>a@b</code>  </p>
  
  <p>What my code is giving me...</p>
  
  <ul>
  <li><code>a@b.c</code> prints <code>a@b</code>  </li>
  <li><code>a@b.c.d</code> prints <code>a@b.c</code>  </li>
  <li><code>a@b.c.d.e</code> prints <code>a@b.c.d</code>  </li>
  </ul>
  
  <p>what should find be so that it only gets a@b?</p>