Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/timofurrer/pandoc-plantuml-filter
Pandoc filter for PlantUML code blocks
https://github.com/timofurrer/pandoc-plantuml-filter
filter hacktoberfest latex markdown pandoc plantuml
Last synced: 14 days ago
JSON representation
Pandoc filter for PlantUML code blocks
- Host: GitHub
- URL: https://github.com/timofurrer/pandoc-plantuml-filter
- Owner: timofurrer
- License: mit
- Created: 2018-04-02T13:48:44.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-10-11T06:33:04.000Z (about 1 month ago)
- Last Synced: 2024-10-23T08:52:10.468Z (21 days ago)
- Topics: filter, hacktoberfest, latex, markdown, pandoc, plantuml
- Language: Python
- Homepage: https://pypi.org/project/pandoc-plantuml-filter
- Size: 29.3 KB
- Stars: 104
- Watchers: 8
- Forks: 27
- Open Issues: 11
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pandoc-plantuml-filter
Pandoc filter which converts PlantUML code blocks to PlantUML images.
````
```plantuml
Alice -> Bob: Authentication Request
Bob --> Alice: Authentication ResponseAlice -> Bob: Another authentication Request
Alice <-- Bob: another authentication Response
```
````## Usage
Install it with pip:
```
pip install pandoc-plantuml-filter
```And use it like any other pandoc filter:
```
pandoc tests/sample.md -o sample.pdf --filter pandoc-plantuml
```The PlantUML binary must be in your `$PATH` or can be set with the
`PLANTUML_BIN` environment variable.### Additional parameters
You could pass additional parameters into `plantuml` filter which will be processed as picture's options:
````
```{ .plantuml height=50% plantuml-filename=test.png }
Alice -> Bob: Authentication Request
Bob --> Alice: Authentication Response
```
````The `plantuml-filename` parameter create a symlink for the destination picture, which could be used in the same file as an image directly.
### Control the output file-type
The generated file-type can be controlled via the file metadata:
```
---
plantuml-format: svg
---
```Or directly via the cli `--metadata` argument.
```
pandoc tests/sample.md -o sample.pdf --filter pandoc-plantuml --metadata=plantuml-format=svg
```## But there is ...
There are a few other filters trying to convert PlantUML code blocks however
they all failed for me.