vim-literate-markdown

A Vim plugin to replicate a subset of Org mode's literate programming, for Markdown files.
git clone git://git.alex.balgavy.eu/vim-literate-markdown.git
Log | Files | Refs | README

only_specific_language.md (453B)


      1 <!-- :Tangle(python) DIRNAME/FILENAME.py -->
      2 This file has different languages.
      3 Only python blocks should be tangled to the output file, everything else should be ignored.
      4 
      5 The python:
      6 
      7 ```python
      8 def some_method(x):
      9     print(x)
     10 ```
     11 
     12 This should be ignored:
     13 
     14 ```sh
     15 echo "Should not be tangled"
     16 ```
     17 
     18 And this should be tangled:
     19 
     20 ```python
     21 some_method(2)
     22 # Here's a comment for good measure
     23 ```
     24 
     25 And ignored:
     26 
     27 ```r
     28 frame <- data.frame(somecol=c(1,2))
     29 ```