title: Paste multiple lines inside tags as separate line each - Sublime text
body: <p>I have to set a list of title/authors item inside an html page, with each title/author line inside a <code>&lt;li&gt;</code> like this:<br></p>
  
  <pre><code>&lt;ul&gt;
    &lt;li&gt; title name - &lt;em&gt;author name&lt;/em&gt;&lt;/li&gt;
    &lt;li&gt; title name - &lt;em&gt;author name&lt;/em&gt;&lt;/li&gt;
    &lt;li&gt; title name - &lt;em&gt;author name&lt;/em&gt;&lt;/li&gt;
    and so on...
  &lt;/ul&gt;
  </code></pre>
  
  <p>They gave me an Excel file with two columns, one for title and one for authors, with about 90-100 rows.<br><br>
  What is the best and quickest way to obtain a list with <code>&lt;li&gt;</code>s like those stated above? (I use Sublime Text 2)<br><br>
  Simply copy/pasting inside Sublime Text 2, i have a separate line for each title/author row, like this</p>
  
  <pre><code>title name author name
  title name author name
  title name author name
  </code></pre>
  
  <p>nothing else..</p>
  
  <p>I can easely wrap every single line inside an <code>&lt;li&gt;</code> thx to: 
  <li> menu <strong>Selection</strong> -> <strong>Split into Lines</strong> (Cmd/Ctlr + Shift + L)<br><br>
  and typing the tags, but then i'm stuck to insert, in a sort of automated way, the dash ( - ) after the titles and the <code>&lt;em&gt;</code>s for the authors.
  <br><br>
  My best guess is (but I really don't know how to do that) to find a way to copy/paste a bunch of lines and then paste them where every single cursor stand, each as a separate line like this (consider the <strong><code>|</code></strong> as the cursor):</p>
  
  <pre><code>*copy* authors name as single lines
  
  |author name1
  |author name2
  |author name3 
  |author name4
  
  *paste* authors as single line each where the cursor "|" stands
  
  &lt;li&gt;title name - &lt;em&gt; |author name1 &lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;title name - &lt;em&gt; |author name2 &lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;title name - &lt;em&gt; |author name3 &lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;title name - &lt;em&gt; |author name4 &lt;/em&gt;&lt;/li&gt;
  </code></pre>
  
  <p>Unfortunately what actually happens (in sublime text 2) is this:</p>
  
  <pre><code>&lt;li&gt;title name - &lt;em&gt; |author name1
                         author name2
                         author name3 
                         author name4 &lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;title name - &lt;em&gt; |author name1
                         author name2
                         author name3 
                         author name4 &lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;title name - &lt;em&gt; |author name1
                         author name2
                         author name3 
                         author name4 &lt;/em&gt;&lt;/li&gt;
  &lt;li&gt;title name - &lt;em&gt; |author name1
                         author name2
                         author name3 
                         author name4 &lt;/em&gt;&lt;/li&gt;
  </code></pre>
  
  <p>all the copied lines simply get pasted in block for every single cursor</p>