title: Sed to remove underscores and promote character
body: <p>I am trying to migrate some code from an old naming scheme to the new one the old naming scheme is:</p>
  
  <pre><code>int some_var_name;
  </code></pre>
  
  <p>New one is</p>
  
  <pre><code>int someVarName_:
  </code></pre>
  
  <p>So what I would ilke is some form of sed / regexy goodness to ease the process. So fundamentally what needs to happen is:<br>
  find lower case word with contained _ replace underscore with nothing and promote the char to the right of the _ to uppercase. After this appending an _ to the end of the match.</p>
  
  <p>Is it possible to do this with Sed and/or Awk and regex? If not why not?</p>
  
  <p>Any examples scripts would be appreciated.</p>
  
  <p>thanks very much for any assistance.</p>
  
  <p>EDIT:<br>
  For a bit of clarity the renaming is for a number of files that were written with the wrong naming convention and need to be brought into line with the rest of the codebase. It is not expected that this do a perfect replace that leaves everything in a compilable state. Rather the script will be run and then looked over by hand for any anomalies. The replace script would be purely to ease the burden of having to correct everything by hand, which i'm sure you would agree is considerably tedious.</p>