piwik/piwik — pull request #6891 by mnapoli (2014-12-22 05:09:05+00:00)
Title: Simplified bootstrap files

We have the following entry points for the application:

- `index.php`
- `console`
- `piwik.php`
- `js/tracker.php`
- `misc/cron/archive.php`
- `tests/PHPUnit/bootstrap.php`
- `tests/PHPUnit/proxy/*.php`
- `tests/resources/staticFileServer.php`

And there's of course a lot of duplicated code in them.

I've tried to identify the common logic and put it in a **core/bootstrap** file.

This is a PHP file, not a class, because it needs to be PHP 4 compatible. If you see a better way than this I'll gladly consider it, I'm not against having a raw PHP file but having a `Bootstrap` class would allow to use private methods and eventually we might move the configuration of the container in there.