Skip to content

neuhalje/ob-nwdiag.el

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 

Repository files navigation

ob-nwdiag.el

An extension for org-babel to support nwdiag.

Installation

Please install from the repo.

Now you could enable this package in your Emacs config with:

(org-babel-do-load-languages 'org-babel-load-languages
 '((nwdiag . t))
)

Example

#+BEGIN_SRC nwdiag :tool nwdiag-3.5 :file ololo.png
nwdiag {
  network dmz {
      address = "210.x.x.x/24"

      web01 [address = "210.x.x.1"];
      web02 [address = "210.x.x.2"];
  }
  network internal {
      address = "172.x.x.x/24";

      web01 [address = "172.x.x.1"];
      web02 [address = "172.x.x.2"];
      db01;
      db02;
  }
}
#+END_SRC

Arguments

There are some things you could customize:

- `:tool` if you have nwdiag in unusual location or want to use seqdiag or [others](http:https://blockdiag.com/en/#table-of-contents)
- `:transparency t` to make transparent background of diagram (PNG only)
- `:antialias t` pass diagram image to anti-alias filter
- `:font` if you want the `:tool` to use provided font
- `:size` if you want the `:tool` to use custom size
- `:type` if you want the `:tool` to use different file format type, e.g. pdf, svg

Errors and output

It recreates a buffer with name *ob-nwdiag* every time you evaluating something.

There will be errors and output.

About

nwdiag support for babel

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages