Auto-detect composer installed CakePHP folder.

It feels a little bit awkward having to adjust index.php and test.php manually after baking a new repo.
And especially having to add complete lines to make composer work out of the box.

This patch makes the auto-detection work without any modifications necessary.
I have been using the other version, which is having app on its own and vendors in the containing folder. But I guess either is fine