yiisoft/yii2 — pull request #2059 by nineinchnick (2014-01-19 12:57:16+00:00)
Title: [WIP] Advanced file excluding/including ported from git

Fixes #2048. This extends/fixes the _except/only_ options for _helpers/BaseFileHelper::findFiles()_ method to support not only file suffixes but wildcards.

The solution is ported from git (1.8.5.3, dir.c) to support same syntax as in _.gitignore_ files. Only the double asterisk (**) is not supported, because it requires the use of _wildmatch()_ function instead of _fnmatch()_.

This is a work in progress, that is it requires some cleanup and/or refactoring before being accepted. Please wait with such comments after the main idea will be accepted.

If the idea is accepted unit tests should be written.