Solved thread

This post is marked as solved. If you think the information contained on this thread must be part of the official documentation, please contribute submitting a pull request to its repository.

Letters case in name of files and folders

Hi all, I have really strange problem here. On my vagrant instance I use folders 'controllers' and 'models' but on production server it works only when I rename folders to 'Controllers' and 'Models'. Both servers on Ubuntu 14.04 with case sensitive ext4. I use class loader by namespace like this:

    'MyApp' => __DIR__ . '/',
    'PhpAmqpLib' => __DIR__ . '/../vendor/PhpAmqpLib'

How can it be? =)

The answer: It turns that vagrant sync folders doesn't support case sensitive filenames if it is not supported on the host. Sorry. =(


Okey, extended answer is:

Vagrants 'sync folders' supports case sensitive filenames only if filesystems of both host and virtual mashines are case sensitive. That's why you should use linux as host =)

Next problem is that git doesn't care about case. So, when I perform pull on production server it downloads files and folders in lower case that cause known problems. So I used next command:

git mv controllers _controllers
git mv _controllers Controllers

to rename folders in git and now everything is okey.

Hope it will help somebody =)