diff --git a/cmd/rlpdump/main.go b/cmd/rlpdump/main.go index 10eea1fde075ecd844114d1996b7811b7060bc20..7d328e59b33ce0c05edf95ae0984b18faec62203 100644 --- a/cmd/rlpdump/main.go +++ b/cmd/rlpdump/main.go @@ -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() { @@ -82,6 +83,9 @@ func main() { break } fmt.Println() + if *single { + break + } } }