Hi:
we are working in a YII app that will go to have a lot of CConsoleCommand, Yii by default use the path "protected/commands" but we want to create subfolders inside the "protected/commands" to organize our CConsoleCommand.
How I can do this?
Thanks
Luis
Hi !
You can uses subfolde for your command, but you must map command. Example i have TestCommand in example subfolder of commands:
<?php
// This is the configuration for yiic console application.
// Any writable CConsoleApplication properties can be configured here.
return array(
'basePath'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..',
'commandMap' => array(
'test' => array(
'class' => 'application.commands.example.TestCommand'
)
),
...
- And call command: yiic test