Custom module files written in Windows aren't being recognized when migrated to Linux I've developed several custom modules in my development environment. My current development environment is Drupal 8 in XAMPP running under Windows and I write the code in Netbeans. I'm getting close to production and I wanted to setup a development environment that mirrors production, so I setup Drupal in CentOS running in VirtualBox.

The problem is, is when I copied over my custom modules Drupal won't recognize them. They don't show up at all under Extend in the list of modules to install. I'm able to open and view the files in VIM and they don't look corrupted in any way. Also, If I create a module natively in CentOS it is recognized just fine. I'm reasonably confident permissions aren't the issue, I've tried setting everything to 777. I'm not 100% sure being written in Windows is the root cause however all the evidence points that way.

Is this a common problem? If so, what can I do to make Drupal recognize these files?

Thanks!
I believe I've figured it out. This issue may not be consider specific to Drupal but Drupal does seem to be a little more particular about files copied over from a Windows dev site.

To get the files to work I had to do two things and in this order:


Recursively convert all files in "/path" from Windows format to Linux format.


  find /path -type f -print0 | xargs -0 dos2unix

Even after doing step #1 Drupal didn't like the files. I ran this to build a new directories.


  rsync -r /input-path /output-path