title: Create an Emacs semi-interactive macro
body: <p>I would like to create a quick Emacs macro (with <code>C-x (</code>)  which takes some user input from the minibuffer each time it's executed.</p>
  
  <p>The usage scenario is this:</p>
  
  <p>You have a complex text to change where the regexp query substitution just doesn't cut it, and you want to create a macro which:</p>
  
  <ol>
  <li>does some complex changes in the current line of text</li>
  <li>position the cursor at a specific point</li>
  <li><strong>asks the user for some text in the minibuffer</strong></li>
  <li>possibly executes some other action, then exits</li>
  </ol>
  
  <p>I have tried using </p>
  
  <pre><code>M-x eval-expression
  </code></pre>
  
  <p>and</p>
  
  <pre><code>(insert-text (read-from-minibuffer "&gt;"))
  </code></pre>
  
  <p>but after creation, the macro obviously (in retrospect... :) ) repeats the same keystrokes and therefore doesn't give me a chance to insert some new text.</p>
  
  <p>Can this be done?</p>
  
  <p>Thank you for the help!</p>