title: Change meta and control keys in emacs for mac keyboard
body: <p>There are several things I'd like to do:</p>
  
  <ul>
  <li>leave the left control key as is</li>
  <li>map the left command key so it's a meta key</li>
  <li>map the right command key so it's a meta key</li>
  <li>map the right up arrow so it's a control key</li>
  </ul>
  
  <p>I know the three map commands need to be of the form:</p>
  
  <pre><code>(define-key KEYMAP KEY DEF)
  </code></pre>
  
  <p>Also I know my <code>.emacs</code> file located in my home directory. However, I'm not sure how to define these three values or if I have the right idea.</p>
  
  <p>One other thing, I installed emacs 24, but I noticed that mac OSX seems to also come with emacs 22. I'd like both to function the same. Is there a way to make sure the key mappings match? Or even better replace emacs 22 with 24 in the terminal?</p>