Skip to content

Commit

Permalink
wordsmith some long help text
Browse files Browse the repository at this point in the history
  • Loading branch information
verdverm committed Jun 24, 2022
1 parent fd91e75 commit 2667a02
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .hof/shadow/Cli/cmd/hof/cmd/gen.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ var genLong = `render directories of code using modular generators
Doc: https://docs.hofstadter.io/first-example/
hof gen -g frontend -g backend design.cue`
hof gen app.cue -g frontend -g backend -g migrations`

func init() {

Expand Down
8 changes: 6 additions & 2 deletions .hof/shadow/Cli/cmd/hof/cmd/render.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,12 @@ import (
"github.com/hofstadter-io/hof/cmd/hof/flags"
)

var renderLong = `hof render joins CUE with an extended Go base text/template system
https://docs.hofstadter.io/code-generation/template-writing/
var renderLong = `hof render joins CUE with Go's text/template system
# Learn about writing templates, with extra functions and helpers
https://docs.hofstadter.io/code-generation/template-writing/
hof gen is a modular and composable version of this command
# Render a template
hof render data.cue -T template.txt
Expand Down
2 changes: 1 addition & 1 deletion cmd/hof/cmd/gen.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ var genLong = `render directories of code using modular generators
Doc: https://docs.hofstadter.io/first-example/
hof gen -g frontend -g backend design.cue`
hof gen app.cue -g frontend -g backend -g migrations`

func init() {

Expand Down
8 changes: 6 additions & 2 deletions cmd/hof/cmd/render.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,12 @@ import (
"github.com/hofstadter-io/hof/lib/gen"
)

var renderLong = `hof render joins CUE with an extended Go base text/template system
https://docs.hofstadter.io/code-generation/template-writing/
var renderLong = `hof render joins CUE with Go's text/template system
# Learn about writing templates, with extra functions and helpers
https://docs.hofstadter.io/code-generation/template-writing/
hof gen is a modular and composable version of this command
# Render a template
hof render data.cue -T template.txt
Expand Down
23 changes: 14 additions & 9 deletions design/cli/cmds/gen.cue
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,7 @@ import (
Usage: "gen [files...]"
Aliases: ["G"]
Short: "render directories of code using modular generators"
Long: """
\(Short)
Doc: https://docs.hofstadter.io/first-example/
hof gen -g frontend -g backend design.cue
"""
Long: GenLongHelp

Flags: [...schema.#Flag] & [
{
Expand Down Expand Up @@ -66,10 +60,21 @@ import (
]
}

GenLongHelp: """
render directories of code using modular generators
Doc: https://docs.hofstadter.io/first-example/
hof gen app.cue -g frontend -g backend -g migrations
"""

RenderLongHelp: """
hof render joins CUE with an extended Go base text/template system
https://docs.hofstadter.io/code-generation/template-writing/
hof render joins CUE with Go's text/template system
# Learn about writing templates, with extra functions and helpers
https://docs.hofstadter.io/code-generation/template-writing/
hof gen is a modular and composable version of this command
# Render a template
hof render data.cue -T template.txt
Expand Down

0 comments on commit 2667a02

Please sign in to comment.