ethresearch / sharding-p2p-poc

Proof of Concept of Ethereum Serenity Peer-to-Peer Layer on libp2p PubSub System
40 stars 19 forks source link

CLI parsing is not clean #61

Closed mhchia closed 5 years ago

mhchia commented 5 years ago

What is wrong?

The argument parsing is pretty nasty now.

How can it be fixed?

We might want to use some tool like https://github.com/urfave/cli, or just refactor it.

ChihChengLiang commented 5 years ago

Refactoring to switch and function looks beautiful too.

https://github.com/ethereum/go-ethereum/blob/master/build/ci.go#L171-L204

mhchia commented 5 years ago

@ChihChengLiang The style looks pretty good! And also it doesn't need much effort to refactor. I vote for geth's style.