title: Expect script, help handling multiple options in order, and only once
body: <pre><code>expect {
      "Error: 1*#" {
          send_user "\nSpecific Error\n"
      }
      "Error: *#" {
          send_user "\nError Happened\n"
      }
      "*#" {
          send_user "\nNo Error\n"
      }
  }
  </code></pre>
  
  <p>Basically what I'm looking to happen is</p>
  
  <ol>
  <li>Check for text "Error: 1", anything between and then the "#" prompt.</li>
  </ol>
  
  <p>If found, send first message to the user</p>
  
  <ol start="2">
  <li>If that's not found check for "Error:" anything at all, and then the "#" prompt.</li>
  </ol>
  
  <p>If found, send an error message to the user</p>
  
  <ol start="3">
  <li>If none of that is met, check for just the "#" prompt </li>
  </ol>
  
  <p>If found, send a message to the user.</p>
  
  <p>I can't reliably get it to work in that order and ONLY do one of those.
  Any tips?</p>