title: VIM - How do I assign different mappings for a key depending on whether the line is empty?
body: <p>I want to assign different commands depending on context.</p>
  
  <p>I'm trying to do something like this:</p>
  
  <pre><code>if line is empty:
      map x key to y command
  else
      map x key to z command
  </code></pre>