It would also be slick to be able to do something like:
rock::require('somePackage');
namespace somePackage;
funcDefinedInSomePackage();
$x = new ClassFromSomePackage;
Where rock::require at dev time would check for the latest version of "somePackage" on the server, if it is newer than what is there (or it is not there at all) it will download the phar, put it in the library and then load the phar.
2 comments:
I agree. But since I am the only commenter in 2 years on this I suspect it's unlikely to happen. :( PHP has 2 big problems, in my opinion. There's no real dependency management system (like ruby gems for ruby/rails) and hosting companies are VERY slow to upgrade to new versions of PHP. So you end up pretty much always re-inventing the wheel and trying to support 5 year old technology.
After leaving my first comment, I came across this post and found it very interesting. I thought I'd share it here too: http://philsturgeon.co.uk/blog/2012/03/packages-the-way-forward-for-php
Post a Comment