How to specify Lumen (or Laravel) version on new installation?

Ifnot picture Ifnot · Mar 23, 2016 · Viewed 10.9k times · Source

I want to install a specific version of Laravel Lumen (5.1 instead of the lastest one 5.2) on a new project.

From the documentation :

lumen new blog

or :

composer create-project laravel/lumen --prefer-dist

Does not work : it install the lastest one.

Answer

Ifnot picture Ifnot · Mar 23, 2016

Create a project using the composer command :

Create a Laravel 5.1 project into the blog folder :

composer create-project laravel/laravel blog "5.1.*"

Create a Lumen 5.1 project into the blog folder :

composer create-project laravel/lumen blog "5.1.*"