added command line feature