Apps: divide the modules in direct command modules, support library and init