simplified from_cli.sh