Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

why does Laravel 4 gitignore composer.lock

Why does the default laravel4 have the composer.lock file included in the .gitignore repo?

It seems to contradict composers recommendations to commit this file into VCS. I was wondering if there was something I didn't know that justified this?

like image 352
veilig Avatar asked Feb 01 '14 23:02

veilig


Video Answer


2 Answers

According to the author of Laravel here https://github.com/laravel/framework/issues/1412:

It is recommended for your own apps, not for frameworks.

like image 61
elclanrs Avatar answered Sep 19 '22 08:09

elclanrs


It's not clear from the question if you meant the framework or the app. Instead of asking for a clarification, I decided to write this instead for future confused users.

The problem is, it's ignored not only in the framework but in the app too. The app is what you get when you install Laravel as a project (i.e. not for the purposes of developing it and sending pull requests but for using it in a project of yours).

In contrast, the Symfony project makes a distinction here and doesn't include the lock file in the .gitignore of the the Symfony Standard Edition distribution (the app) unlike the Symfony framework.

There are already at least two issues and one pull request regarding composer.lock: issue 1696, issue 2293 and PR 2591.

like image 26
Halil Özgür Avatar answered Sep 18 '22 08:09

Halil Özgür