Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/MaxvdKolk/vimwikigraph
vimwikigraph - visualise vimwiki links using the graphviz dot language
https://github.com/MaxvdKolk/vimwikigraph
Last synced: 3 months ago
JSON representation
vimwikigraph - visualise vimwiki links using the graphviz dot language
- Host: GitHub
- URL: https://github.com/MaxvdKolk/vimwikigraph
- Owner: MaxvdKolk
- License: mit
- Created: 2020-05-30T10:44:58.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2021-05-31T11:42:50.000Z (over 3 years ago)
- Last Synced: 2024-07-14T12:33:15.849Z (4 months ago)
- Language: Go
- Size: 359 KB
- Stars: 53
- Watchers: 4
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-starred - MaxvdKolk/vimwikigraph - vimwikigraph - visualise vimwiki links using the graphviz dot language (others)
README
# vimwikigraph
![Go](https://github.com/MaxvdKolk/vimwikigraph/workflows/Go/badge.svg)
`vimwikigraph` walks all files in a
[vimwiki](https://github.com/vimwiki/vimwiki) directory and builds a
graph between the encountered files and their internal references. The
code supports vimwiki-style links `[[link]]`, `[[link|description]]`
and markdown-style links `[description](link)`. The graph is
converted to the DOT language
using [`dot`](https://github.com/emicklei/dot). The results can then be
visualised with [graphviz](https://www.graphviz.org/about/), e.g. using
`dot`, `neato`, `fdp`, etc.The graph visualises your notes and their connections, possibly
providing new insights.## Usage
```
./vimwikigraph $HOME/vimwiki | dot -Tpng > test.png && open test.png
````-diary`: collapse all diary entries under a single node `diary.wiki`
`-cluster`: cluster subdirectories as subgraphs
`-l`: only nodes with at least `l` edges are inserted. The inserted nodes are
inserted with all their edges. Thus, nodes with less than `l` edges can appear
when they are connected to other nodes that do satisfy the requirement.
For `-l 0`, all nodes are inserted.`--ignore REGEX`: ignores any encountered path matching `REGEX`
Note: any trailing argument are considered directories to be skipped.
## Examples
To illustrate `/example/` contains some `.wiki` files and also a
diary, `/example/diary/*.wiki`. Running `vimwikigraph` produces the
following output. All `diary` files are collapse by default into a
single node. Any connections to and from any diary files are simply
an arrow point in to, or out of, the diary.```
./vimwikigraph example | dot -Tpng > example.png
```![](./doc/example.png)
The `-diary` flag ensures all diary items are shown as nodes.
```
./vimwikigraph example -diary | dot -Tpng > example.png
```![](./doc/example_diary.png)
The `-cluster` flag adds all diary items to a subgraph.
```
./vimwikigraph example -diary -cluster | dot -Tpng > example.png
```![](./doc/example_diary_cluster.png)
The `--ignore` allows to filter files by the given regex, e.g. to ignore
any matches with `alice` or `bob````
./vimwikigraph example -diary -cluster --ignore "alice|bob" | dot -Tpng > example.png
```![](./doc/example_ignore_alice_or_bob.png)
## Installation
```
go get github.com/maxvdkolk/vimwikigraph
```## Change log
- 2021/05/31: add `--ignore` flag to ignore any path that matches the provided
regex.