Skip to content

AntoineThebaud/jsonnetdoc

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

jsonnetdoc

/!\ This is a fork from https://github.com/trotttrotttrott/jsonnetdoc that seem to be no longer maintained

Documentation parser for JSDoc style comments in Jsonnet.

This is not even close to covering the complete spec. Only descriptions, @name, @param, and @return. The initial motivation for this was Grafonnet which has used this documentation style for quite a while without something to parse it.

See testdata/ for documentation examples.

Installation

go install github.com/AntoineThebaud/jsonnetdoc@master

Or clone the repo to build jsonnetdoc from source.

Usage

Expects a single argument which should be a path to your Jsonnet files. By default, it will output a JSON representation of your documentation. If you pass, the --markdown flag, it will instead output Markdown.

Usage:
  jsonnetdoc <input-file|dir> [flags]

Flags:
  -h, --help       help for jsonnetdoc
      --markdown   output markdown instead of JSON

Example:

jsonnetdoc testdata --markdown

Same command using Docker:

docker run --rm \
  -v $PWD:$PWD \
  -w $PWD \
  AntoineThebaud/jsonnetdoc \
  testdata --markdown

About

Documentation parser for JSDoc style comments in Jsonnet.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

  • Go 87.4%
  • Makefile 10.2%
  • Dockerfile 2.4%