title: bash: ps grep for process with Umlaut (OS X)
body: <p>in a shell script i need to find out whether a specific application is still running or not. this would be a simple task to do if our application name would not contain any <strong>Umlauts</strong> (äöüàéè...). how can i reliably "grep" for my process in question?</p>
  
  <p>the shell script gets the application name as parameter, "<strong>amétiq siMed Büro.app</strong>" in this example. There are several customized copies running at the same time, they are named differently, and the script should check only a specific application (the one it gets via param) and ignore the others.</p>
  
  <p>no hits at all when using grep for the specific app-name (param):</p>
  
  <pre><code>bash&gt; ps ax | grep "amétiq siMed Büro.app"
  
  bash&gt;
  </code></pre>
  
  <p>too many hits:</p>
  
  <pre><code>bash&gt; ps ax | grep "/[A]pplications/am" 
   4335   ??  S      5:19.01 /Applications/ame?M^Atiq siMed Bu?M^Hro.app/Contents/MacOS/siMed2
  10188   ??  S      0:03.18 /Applications/ame?M^Atiq siMed SUPPORT.app/Contents/MacOS/siMed2
  </code></pre>
  
  <p>again no hits when trying to manually narrow grep:</p>
  
  <pre><code>bash&gt; ps ax | grep "/[A]pplications/am" | grep "Büro"
  
  bash&gt;
  </code></pre>
  
  <p>it seems that grep stops working after the position of the first occurrence of an Umlaut character.</p>
  
  <p>i also tried <code>lsof</code> - no success. any idea what to try next?</p>
  
  <p>running OS X 10.7-10.9</p>