I shit on PHP all the time, but I haven't actually done anything substantial with it in quite a while. I wrote a couple of WHMCS modules, including open-sourcing one, but none of that was more than elaborate copy+pasting and a bit of logic involved.

Someone on #mumble mentioned about how PHP was "only as bad as you let it be" and that when you use Laravel and some other shit it protects you from a lot of the braindeadedness, so in the interests of impartiality I decided to give it a go for a small project I've been thinking about building.

First step was following the tutorial in my Debian VM, which worked well up till this point:

$ php artisan make:migration create_tasks_table --create=tasks
PHP Parse error:  syntax error, unexpected 'class' (T_CLASS), expecting identifier
(T_STRING) or variable (T_VARIABLE) or '{' or '$' in /home/fwaggle/src/tasks/artisan
on line 31

What the fuck is this? Off to Google to try find out why, and that didn't take long at all. My PHP is too old.

I've been meaning to upgrade the VM to Jessie for a month or so, so I suppose I'll do it. But why the fuck did Composer - the PHP dependency manager - let me install Laravel when my PHP is clearly out of date?

Well, a few more moments digging around in the Github repos for the various things leads me to the conclusion: I installed laravel/installer via Composer. laravel/laravel contains the lines "require": { "php": ">=5.5.9",, whereas laravel/installer does not. Still, it depends on laravel/framework, which does have the require lines in it... surely that should have stopped it?

I'll have to investigate more, but it's bed time now.

Horsham, VIC, Australia fwaggle

Published:


Modified:

Never

Filed under:


Location:

Horsham, VIC, Australia

Navigation: Older Entry Newer Entry