title: fnmatch and recursive path match with `**`
body: <p>Is there any built-in or straightforward way to match paths recursively with double asterisk, e.g. like <a href="http://lorenzod8n.wordpress.com/2007/05/10/recursive-globbing-in-zsh/" rel="nofollow">zsh</a> does?</p>
  
  <p>For example, with </p>
  
  <pre><code>path = 'foo/bar/ham/spam/eggs.py'
  </code></pre>
  
  <p>I can use <a href="http://docs.python.org/2/library/fnmatch.html#fnmatch.fnmatch" rel="nofollow">fnmatch</a> to test it with</p>
  
  <pre><code>fnmatch(path, 'foo/bar/ham/*/*.py'
  </code></pre>
  
  <p>Although, I would like to be able to do:</p>
  
  <pre><code>fnmatch(path, 'foo/**/*.py')
  </code></pre>
  
  <p>I know that fnmatch <a href="https://github.com/python-git/python/blob/master/Lib/fnmatch.py" rel="nofollow">maps its pattern to regex</a>, so in the words case I can roll my own fnmatch with additional <code>**</code> pattern, but maybe there is an easier way</p>