shama/grunt-hub — pull request #45 by dylancwood (2014-06-21 05:17:07+00:00)
Title: Avoid infinite sleep if no files are matched

This is another solution to Issue #44.

**Thanks for fixing the issue so quickly.** I was in the middle of creating a simple test environment for my solution to the same problem when you implemented the fix. You were amazingly fast in your response and solution, so please don't be offended by me offering an alternative.

# Difference between your patch and this one:
Your patch will only notify the user that patterns do not match if **none** of their patterns match. This solution will produce a log-warning if any of the patterns of this.files do not produce any matches, as well as output which patterns did not match.

This patch also fits into the existing event flow, and avoids needing to re-map all the files.

# Test:

Feel free to clone https://github.com/dylancwood/grunt-hub-sleep-test.git, and run ``npm install`` then ``grunt hub --force`` to see it in action.

I won't take offense if you decide to stay with your solution, but I thought I'd send this your way since the work was already done on it.

Next time, I will be sure to finish the work and testing before creating any issues on your projects :+1: