Recent posts
Recent comments
- In Working with a company that embraces open source
- Guy Steels wrote: And a big thank you for open sourcing your plugins. When we look if certain functionality is...
- In Marius Wilms - The CakePHP Media Plugin
- Sotir wrote: Some practice use examples will be nice to have around...
- In Felix Geisendörfer - Recipies for successful CakePHP projects
- Felix Geisendörfer wrote: http://felixge.s3.amazonaws.com/09/cakephp-receipes.pdf (sorry, 8mb download)
- In Joël Perras - Demystifying Webservices in CakePHP
- Neil Crookes wrote: I have an upcoming project that could use the Google Chart / Visualisation API so would be...
Categories
Neil Crookes - Bake Master Class
Written on Tue, Jul 14th 2009, 05:25 in CakeFest
After an introduction to bake, and what this shell means within CakePHP, Neil went on to explain and show examples of the code generation templates and capabilities provided by default.
The bake shell is broken down into tasks and a main shell. These tasks separate out the logic required for various main task subsets including controller, model and view baking, amongst others. The main bake shell is found in the CakePHP directory cake/console/libs/bake.php. Tasks used by this shell are defined in the $tasks variable. Bake extends the CakeShell class and executes calls based on whether the users want interactive or non-interactive tasks through the __interactive() and bake() methods respectively.
Neil made the suggestion that a persistent MySQL connection might be a good idea to stop database connection timeouts.
Following this introduction, a great walkthrough of customisation of the bake process and templates was demonstrated. This included the addition of a new Shell that allows for multiple bakes to be done automatically of the same type. Neil has been kind enough to host the code, and you can find this over at the CakeFest downloads page.

What is OpenID?
OpenID is a new open standard that lets you sign in to web sites with a single URL that you own. This URL can be your homepage or blog, or it can be provided to you by a web site you use. In either case, you only have to sign in once to your OpenID provider and so you only need to maintain a single password.Learn more.
How is CakeDC using OpenID?
You can use your OpenID identity when posting comments on the site. When you see a form field with
entering your OpenID identity is sufficient to allow your post. We also accept Google or Yahoo! identities. Simply use either "google.com" or "yahoo.com" and our OpenID library will locate your information from the appropriate source.
Comments:
Add comment