Codeigniter Matches is a PHP CLI script that allows you to write controllers, models, views and migrations faster.
Codeigniter Matches is a cli script that allows you to write controllers, models and views faster.
php -v
$config['uri_protocol'] = 'AUTO';
$config['uri_protocol'] = isset($_SERVER['REQUEST_URI']) ? 'PATH_INFO' : 'CLI';
php index.php matches
You can start using Matches by writing:
php index.php matches [COMMAND]
...where [COMMAND]
can be:
displays all commands available
create:app name_of_app
- creates a MVC stack (controller, model, view) having name_of_app as names.create:controller name_of_controller
- creates a controller having name_of_controller as name. You can put the controller inside a directory. Directories are delimited with ".". So, if you want to create the controller inside controllers/admin, you can do create controller admin.name_of_controller
create:migration name_of_migration name_of_table-(OPTIONAL)
- creates a migration having name_of_migration prefixed with version as file name. If no name_of_table is given, will name the table as the name_of_migration.create:model name_of_model
- creates a model having name_of_model as name. You can put the model inside a directory. Directories are delimited with ".". So, if you want to create the model inside models/admin, you can do create model admin.name_of_model
create:view name_of_view
- creates a view having name_of_view as file name.. You can put the view inside a directory. Directories are delimited with ".". So, if you want to create the view inside views/admin, you can do create view admin.name_of_controller
encryption_key string_to_hash-(OPTIONAL)
- creates an encryption key inside all config.php's found in config folder. If $config['encryption_key'] = '';
doesn't exist or has a value, the encryption key won't be written.This project started from a great idea posted by @veedeoo [veedeoo@gmail.com] on http://www.daniweb.com/web-development/php/code/477847/codeigniter-cli-trainer-script-creates-simple-application
Copyright (C) 2014 @avenirer [avenir.ro@gmail.com] Everyone is permitted to copy and distribute verbatim or modified copies of this license document, and changing it is allowed as long as the name is changed.
DON'T BE A DICK PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
Do whatever you like with the original work, just don't be a dick. Being a dick includes - but is not limited to - the following instances: 1a. Outright copyright infringement - Don't just copy this and change the name. 1b. Selling the unmodified original with no work done what-so-ever, that's REALLY being a dick. 1c. Modifying the original work to contain hidden harmful content. That would make you a PROPER dick. If you become rich through modifications, related works/services, or supporting the original work, share the love. Only a dick would make loads off this work and not buy the original works creator(s) a pint. Code is provided with no warranty. Using somebody else's code and bitching when it goes wrong makes you a DONKEY dick. Fix the problem yourself. A non-dick would submit the fix back. License info: http://www.dbad-license.org/