added command line tool

it's incomplete