added cli.sh support to run from cli