Skip to content

Commit

Permalink
Fix review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
harry-hov committed Dec 21, 2023
1 parent 1899c40 commit 44690ae
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
2 changes: 1 addition & 1 deletion docs/concepts/gno-modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ The gno command-line tool provides several commands to work with the gno.mod fil
- **gno mod init**: small helper to initialize a new `gno.mod` file.
- **gno mod download**: downloads the dependencies specified in the gno.mod file. This command fetches the required dependencies from chain and ensures they are available for local testing and development.
- **gno mod tidy**: removes any unused dependency and adds any required but not yet listed in the file -- most of the maintenance you'll usually need to do!
- **gno mod why**: explains why is specified package or module being kept by gno mod tidy.
- **gno mod why**: explains why the specified package or module is being kept by `gno mod tidy`.

## Sample `gno.mod` file

Expand Down
23 changes: 12 additions & 11 deletions gnovm/cmd/gno/mod.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,17 +91,18 @@ func newModWhy(io commands.IO) *commands.Command {
commands.Metadata{
Name: "why",
ShortUsage: "why <package> [<package>...]",
ShortHelp: "Explain why modules are needed",
LongHelp: `Explain why modules are needed.
Why shows a list of files imports specified packages or modules, explains
why is this package or module being kept by gno mod tidy.
The output is a sequence of stanzas, one for each module name on the
command line, separated by blank lines. Each stanza begins
with a comment line "# module" giving the target module. Subsequent lines
show files that imports the module, one filename per line.
If the package or module is not being used/needed/imported, the stanza
ShortHelp: "Explains why modules are needed",
LongHelp: `Explains why modules are needed.
gno mod why shows a list of files where specified packages or modules are
being used, explaining why those specified packages or modules are being
kept by gno mod tidy.
The output is a sequence of stanzas, one for each module/package name
specified, separated by blank lines. Each stanza begins with a
comment line "# module" giving the target module/package. Subsequent lines
show files that import the specified module/package, one filename per line.
If the package or module is not being used/needed/imported, the stanza
will display a single parenthesized note indicating that fact.
For example:
Expand Down

0 comments on commit 44690ae

Please sign in to comment.