Add events docs template + logic
This commit is contained in:
@@ -3,12 +3,13 @@ package codegen
|
||||
import (
|
||||
"flag"
|
||||
"fmt"
|
||||
"github.com/Masterminds/sprig"
|
||||
"github.com/fsnotify/fsnotify"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
"text/template"
|
||||
|
||||
"github.com/Masterminds/sprig"
|
||||
"github.com/fsnotify/fsnotify"
|
||||
)
|
||||
|
||||
func Proc() {
|
||||
@@ -191,6 +192,9 @@ func Proc() {
|
||||
if genCode {
|
||||
err = genEvents(tpls, eventDefs...)
|
||||
}
|
||||
if genDocs && err == nil {
|
||||
err = genEventsDocs(tpls, docPath+docPathOptions, eventDefs...)
|
||||
}
|
||||
}
|
||||
|
||||
if outputErr(err, "failed to process events:\n") {
|
||||
|
||||
Reference in New Issue
Block a user