Skip to content

Commit

Permalink
feat: improve command description and example
Browse files Browse the repository at this point in the history
  • Loading branch information
ccamel committed Jan 11, 2023
1 parent c48870f commit 2be2ee8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
6 changes: 4 additions & 2 deletions docs/command/okp4d_query_logic_ask.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ executes a logic query and returns the solutions found.

### Synopsis

Executes the [query] for the given [program] file and return the solution(s) found.
Executes the [query] and return the solution(s) found.

Optionally, a program can be transmitted, which will be interpreted before the query is processed.

Since the query is without any side-effect, the query is not executed in the context of a transaction and no fee
is charged for this, but the execution is constrained by the current limits configured in the module (that you can
Expand All @@ -17,7 +19,7 @@ okp4d query logic ask [query] [flags]
### Examples

```
okp4d logic query ask "chain_id(X)." # returns the chain-id
okp4d query logic ask "chain_id(X)." # returns the chain-id
```

### Options
Expand Down
6 changes: 4 additions & 2 deletions x/logic/client/cli/query_ask.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,14 @@ func CmdQueryAsk() *cobra.Command {
cmd := &cobra.Command{
Use: "ask [query]",
Short: "executes a logic query and returns the solutions found.",
Long: `Executes the [query] for the given [program] file and return the solution(s) found.
Long: `Executes the [query] and return the solution(s) found.
Optionally, a program can be transmitted, which will be interpreted before the query is processed.
Since the query is without any side-effect, the query is not executed in the context of a transaction and no fee
is charged for this, but the execution is constrained by the current limits configured in the module (that you can
query).`,
Example: fmt.Sprintf(`$ %s %s query ask "chain_id(X)." # returns the chain-id`,
Example: fmt.Sprintf(`$ %s query %s ask "chain_id(X)." # returns the chain-id`,
version.AppName,
types.ModuleName),
Args: cobra.MinimumNArgs(1),
Expand Down

0 comments on commit 2be2ee8

Please sign in to comment.