From 3f3eef40bde51b1a27763f9638bbabaa897ae52c Mon Sep 17 00:00:00 2001 From: Tony Worm Date: Fri, 10 Mar 2023 02:20:47 -0500 Subject: [PATCH] hof/mod: update command help, also bump hof version in docs --- .hof/shadow/cli/cmd/hof/cmd/mod.go | 31 ++++++++++++++++++------------ cmd/hof/cmd/mod.go | 31 ++++++++++++++++++------------ design/cmds/mod.cue | 31 ++++++++++++++++++------------ docs/code/cmd-help/mod | 31 ++++++++++++++++++------------ docs/config.cue | 2 +- docs/config.yaml | 6 +++--- 6 files changed, 80 insertions(+), 52 deletions(-) diff --git a/.hof/shadow/cli/cmd/hof/cmd/mod.go b/.hof/shadow/cli/cmd/hof/cmd/mod.go index 074c79494..729803f24 100644 --- a/.hof/shadow/cli/cmd/hof/cmd/mod.go +++ b/.hof/shadow/cli/cmd/hof/cmd/mod.go @@ -64,28 +64,35 @@ Both token and sshkey base methods are supported, with preferences: ### Usage -# Initialize this folder as a module (github.com/org/repo) -hof mod init +there are two main commands you will use, init & tidy -# Add or update a dependency -hof mod get github.com/hofstadter-io/hof@latest +# Initialize the current folder as a module +hof mod init (like github.com/org/repo) + +# Refresh dependencies, discovering any new imports +hof mod tidy + +# Add a dependency hof mod get github.com/hofstadter-io/hof@v0.6.8 hof mod get github.com/hofstadter-io/hof@v0.6.8-beta.6 +hof mod get github.com/hofstadter-io/hof@latest // latest semver +hof mod get github.com/hofstadter-io/hof@next // next prerelease +hof mod get github.com/hofstadter-io/hof@main // latest commit on branch -# Tidy module files -hof mod tidy +# Update dependencies +hof mod get github.com/hofstadter-io/hof@latest +hof mod get all@latest -# symlink dependencies from local cache +# Symlink dependencies from local cache hof mod link -# copy dependency code from local cache +# Copy dependency code from local cache hof mod vendor -# update dependencies -hof mod get github.com/hofstadter-io/hof@latest -hof mod get all@latest +# Verify dependency code against cue.mod/sums.cue +hof mod verify -# print help +# This helpful output hof mod help ` diff --git a/cmd/hof/cmd/mod.go b/cmd/hof/cmd/mod.go index 074c79494..729803f24 100644 --- a/cmd/hof/cmd/mod.go +++ b/cmd/hof/cmd/mod.go @@ -64,28 +64,35 @@ Both token and sshkey base methods are supported, with preferences: ### Usage -# Initialize this folder as a module (github.com/org/repo) -hof mod init +there are two main commands you will use, init & tidy -# Add or update a dependency -hof mod get github.com/hofstadter-io/hof@latest +# Initialize the current folder as a module +hof mod init (like github.com/org/repo) + +# Refresh dependencies, discovering any new imports +hof mod tidy + +# Add a dependency hof mod get github.com/hofstadter-io/hof@v0.6.8 hof mod get github.com/hofstadter-io/hof@v0.6.8-beta.6 +hof mod get github.com/hofstadter-io/hof@latest // latest semver +hof mod get github.com/hofstadter-io/hof@next // next prerelease +hof mod get github.com/hofstadter-io/hof@main // latest commit on branch -# Tidy module files -hof mod tidy +# Update dependencies +hof mod get github.com/hofstadter-io/hof@latest +hof mod get all@latest -# symlink dependencies from local cache +# Symlink dependencies from local cache hof mod link -# copy dependency code from local cache +# Copy dependency code from local cache hof mod vendor -# update dependencies -hof mod get github.com/hofstadter-io/hof@latest -hof mod get all@latest +# Verify dependency code against cue.mod/sums.cue +hof mod verify -# print help +# This helpful output hof mod help ` diff --git a/design/cmds/mod.cue b/design/cmds/mod.cue index 70465dda5..da3dc7259 100644 --- a/design/cmds/mod.cue +++ b/design/cmds/mod.cue @@ -183,29 +183,36 @@ import ( ### Usage + + there are two main commands you will use, init & tidy - # Initialize this folder as a module (github.com/org/repo) - hof mod init + # Initialize the current folder as a module + hof mod init (like github.com/org/repo) + + # Refresh dependencies, discovering any new imports + hof mod tidy - # Add or update a dependency - hof mod get github.com/hofstadter-io/hof@latest + # Add a dependency hof mod get github.com/hofstadter-io/hof@v0.6.8 hof mod get github.com/hofstadter-io/hof@v0.6.8-beta.6 + hof mod get github.com/hofstadter-io/hof@latest // latest semver + hof mod get github.com/hofstadter-io/hof@next // next prerelease + hof mod get github.com/hofstadter-io/hof@main // latest commit on branch - # Tidy module files - hof mod tidy + # Update dependencies + hof mod get github.com/hofstadter-io/hof@latest + hof mod get all@latest - # symlink dependencies from local cache + # Symlink dependencies from local cache hof mod link - # copy dependency code from local cache + # Copy dependency code from local cache hof mod vendor - # update dependencies - hof mod get github.com/hofstadter-io/hof@latest - hof mod get all@latest + # Verify dependency code against cue.mod/sums.cue + hof mod verify - # print help + # This helpful output hof mod help diff --git a/docs/code/cmd-help/mod b/docs/code/cmd-help/mod index c27804d27..2e2793412 100644 --- a/docs/code/cmd-help/mod +++ b/docs/code/cmd-help/mod @@ -54,28 +54,35 @@ Both token and sshkey base methods are supported, with preferences: ### Usage -# Initialize this folder as a module (github.com/org/repo) -hof mod init +there are two main commands you will use, init & tidy -# Add or update a dependency -hof mod get github.com/hofstadter-io/hof@latest +# Initialize the current folder as a module +hof mod init (like github.com/org/repo) + +# Refresh dependencies, discovering any new imports +hof mod tidy + +# Add a dependency hof mod get github.com/hofstadter-io/hof@v0.6.8 hof mod get github.com/hofstadter-io/hof@v0.6.8-beta.6 +hof mod get github.com/hofstadter-io/hof@latest // latest semver +hof mod get github.com/hofstadter-io/hof@next // next prerelease +hof mod get github.com/hofstadter-io/hof@main // latest commit on branch -# Tidy module files -hof mod tidy +# Update dependencies +hof mod get github.com/hofstadter-io/hof@latest +hof mod get all@latest -# symlink dependencies from local cache +# Symlink dependencies from local cache hof mod link -# copy dependency code from local cache +# Copy dependency code from local cache hof mod vendor -# update dependencies -hof mod get github.com/hofstadter-io/hof@latest -hof mod get all@latest +# Verify dependency code against cue.mod/sums.cue +hof mod verify -# print help +# This helpful output hof mod help Usage: diff --git a/docs/config.cue b/docs/config.cue index d7070ccf1..b33912cc6 100644 --- a/docs/config.cue +++ b/docs/config.cue @@ -26,7 +26,7 @@ params: { github_repo: "https://github.com/hofstadter-io/hof-docs" time_format_default: "January 2, 2006" keywords: "hof hofstadter documentation docs" - hofver: "v0.6.8-beta.7" + hofver: "v0.6.8-beta.11" cuever: "v0.5.0-beta.5" cuedocBase: "https://pkg.go.dev/cuelang.org/go@\(cuever)" diff --git a/docs/config.yaml b/docs/config.yaml index 2b80d3e78..0816acb27 100644 --- a/docs/config.yaml +++ b/docs/config.yaml @@ -19,17 +19,17 @@ params: github_repo: https://github.com/hofstadter-io/hof-docs time_format_default: January 2, 2006 keywords: hof hofstadter documentation docs - hofver: v0.6.8-beta.7 + hofver: v0.6.8-beta.11 cuever: v0.5.0-beta.5 cuedocBase: https://pkg.go.dev/cuelang.org/go@v0.5.0-beta.5 beta: |- The `hof gen` adhoc feature (`-T`) is only available in the next beta. ``` - go install github.com/hofstadter-io/hof/cmd/hof@v0.6.8-beta.7 + go install github.com/hofstadter-io/hof/cmd/hof@v0.6.8-beta.11 ``` - [Download binaries on GitHub](https://github.com/hofstadter-io/hof/releases/tag/v0.6.8-beta.7) + [Download binaries on GitHub](https://github.com/hofstadter-io/hof/releases/tag/v0.6.8-beta.11) markup: goldmark: renderer: