Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/darwindarak/mdx_bib
A Python-Markdown extension for RMarkdown-style bibliographies and citations
https://github.com/darwindarak/mdx_bib
Last synced: about 2 months ago
JSON representation
A Python-Markdown extension for RMarkdown-style bibliographies and citations
- Host: GitHub
- URL: https://github.com/darwindarak/mdx_bib
- Owner: darwindarak
- License: mit
- Created: 2015-07-13T16:11:45.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2024-06-23T04:15:55.000Z (6 months ago)
- Last Synced: 2024-10-13T23:29:02.128Z (2 months ago)
- Language: Python
- Size: 9.77 KB
- Stars: 14
- Watchers: 2
- Forks: 12
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Bibliography and Citation support for Python-Markdown
This extension to Python Markdown is inspired by the support for citations in [R Markdown][].
It looks for all citation keys with the form `@` inside matching square brackets and appends a bibliography to the output.
The references associated with the citation keys can be defined manually or generated from a BibTeX file.## Installation
Running
```bash
$ python setup.py build
$ python setup.py install
```will install a module named `mdx_bib`.
```python
import markdown
from mdx_bib import CitationsExtensioncite = CitationsExtension(bibtex_file='library.bib', order='unsorted')
html = markdown.markdown(text, extensions=[cite])
```## Syntax
Citation keys are any identifiers inside square brackets with a `@`-prefix
```markdown
Some claim [see @adams98].Some claim [@adams98; @barney04].
```The first line will be converted
```html