Fork me on GitHub

writescript

-p plugin.js

-d data.json

> result.src

plugin based generator tool backpacked with data

writeln('const (')
pushLevel()
for(var k in data) {
  writeln(k+' = "'+data[k]+'"')
}
popLevel()
writeln(')')
{
  "PI": 23,
  "TheAnswer": 43
}
const (
  Pi = 23
  TheAnswer = 43
)

plugin

the plugins are written in javascript and the additional syntax for plugins is kept small and simple.
there is a special keyword to import more plugins.

data

the data you add to the generator need to fit to your plugin and to be formatted as json.

result

the result is plaintext.