adamsanderson/qwandry — pull request #33 by toupeira (2014-02-28 20:45:15+00:00)
Title: Support searches inside packages (issue #32)

Some comments:

- I quickly scrapped the idea with using `require` since that's Ruby specific, and it might not be the best idea to load random code anyway ;-)
- Instead I added a `deep_scan` method on `Qwandry::Package`, so it will work with packages found by any repository
- I'd say adding an option for this isn't necessary, since the presence of a slash already indicates a deep search, and package names can't include slashes anyway
- I've only tested this with the Ruby core library and gems, but the approach should work for NodeJS / Perl as well
- Wildcards are added around the path pattern, so it will easily match paths deep inside the package as well
- If multiple matches are found the user will be presented with a choice as usual, this also works with different versions of the same package since `differentiate` is called before performing the deep search

Let me know what you think, I'll also update the README once we agree on the behaviour.