Skip to content

Commit

Permalink
Merge pull request ethereum#14320 from karalabe/rlpdump-single-flag
Browse files Browse the repository at this point in the history
cmd/rlpdump: support dumping only the first entity
  • Loading branch information
karalabe authored Apr 12, 2017
2 parents 30d706c + 436acb4 commit 4367106
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/rlpdump/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ import (
var (
hexMode = flag.String("hex", "", "dump given hex data")
noASCII = flag.Bool("noascii", false, "don't print ASCII strings readably")
single = flag.Bool("single", false, "print only the first element, discard the rest")
)

func init() {
Expand Down Expand Up @@ -82,6 +83,9 @@ func main() {
break
}
fmt.Println()
if *single {
break
}
}
}

Expand Down

0 comments on commit 4367106

Please sign in to comment.