title: Create appendix with R-code in rmarkdown/knitr
body: <p>Is it possible to get all of the code in a appendix. Say I have two chunks in a document and then some text.</p>
  
  <pre><code>```{r, echo=TRUE}
  x &lt;- 4+5
  x
  ```  
  Above is X output.
  
  ```{r, echo=TRUE}
  y &lt;- 22+325
  y
  ```   
  
  Above is Y output.
  </code></pre>
  
  <hr>
  
  <p>And then I want all of the code in a appendix but shown as if I put <code>eval=FALSE</code> in the chunk.</p>
  
  <p>Something like this</p>
  
  <pre><code>```{r, SHOW_ALL_CODE=TRUE}
  ```
  </code></pre>
  
  <p>Expected output:</p>
  
  <pre><code>Chunk_1
  x &lt;- 4+5  
  x
  
  Chunk_2  
  y &lt;- 22+325  
  y
  </code></pre>