Skip to content

Commit

Permalink
docs(client/debug): correct debug raw-bytes command example (backport
Browse files Browse the repository at this point in the history
#21671) (#21676)

Co-authored-by: lilasxie <thanklilas@163.com>
Co-authored-by: Julien Robert <julien@rbrt.fr>
  • Loading branch information
3 people authored Sep 12, 2024
1 parent 63a535e commit ef8a575
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions client/debug/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -298,14 +298,11 @@ $ %s debug addr cosmos1e0jnq2sun3dzjh8p2xq95kk0expwmd7shwjpfg

func RawBytesCmd() *cobra.Command {
return &cobra.Command{
Use: "raw-bytes [raw-bytes]",
Short: "Convert raw bytes output (eg. [10 21 13 255]) to hex",
Long: fmt.Sprintf(`Convert raw-bytes to hex.
Example:
$ %s debug raw-bytes [72 101 108 108 111 44 32 112 108 97 121 103 114 111 117 110 100]
`, version.AppName),
Args: cobra.ExactArgs(1),
Use: "raw-bytes <raw-bytes>",
Short: "Convert raw bytes output (eg. [10 21 13 255]) to hex",
Long: "Convert raw-bytes to hex.",
Example: fmt.Sprintf("%s debug raw-bytes '[72 101 108 108 111 44 32 112 108 97 121 103 114 111 117 110 100]'", version.AppName),
Args: cobra.ExactArgs(1),
RunE: func(_ *cobra.Command, args []string) error {
stringBytes := args[0]
stringBytes = strings.Trim(stringBytes, "[")
Expand Down

0 comments on commit ef8a575

Please sign in to comment.