Hi!
So basically title is the question. Is there any way to generate migration directly from controller for example, not from an oil?
Or i'm just so stupid that a can't find that way
A migration is just a text file with PHP code, so you can create that from anywhere. But I assume you don't mean that.
The migration files are generated by \Oil\Generate_Migration_Actions, you should be able to call the methods in it from a controller, provided you load the Oil package first. You still need the code to write the generated code to a file.
Alternatively, call \Oil\Generate::migration(), and pass the correct arguments.
Thank you!
It was a great idea to take \Oil\Generate::migration()... It took just to handle if statements where \Cli is called... i just made it something like if(\Fuel::$is_cli and \Cli::bla_bla_bla()) and it work just like it should be!
Thank you one more time, you really made my .... basically, night already