parameters: (fsdir, path)
return_statement: return r
docstring: Yield paths matching the path glob. Sorts as a bonus. Excludes '.' and '..'
docstring_summary: Yield paths matching the path glob. Sorts as a bonus. Excludes '.' and '..'
docstring_tokens: Yield paths matching the path glob . Sorts as a bonus . Excludes . and ..
function: def glob(fsdir, path):
      """
      Yield paths matching the path glob. Sorts as a bonus. Excludes '.' and '..'
      """
  
      dir, leaf = os.path.split(path)
      if dir == '':
          return globpattern(fsdir, leaf)
  
      if hasglob(dir):
          dirsfound = glob(fsdir, dir)
      else:
          dirsfound = [dir]
  
      r = []
  
      for dir in dirsfound:
          fspath = util.normaljoin(fsdir, dir)
          if not os.path.isdir(fspath):
              continue
  
          r.extend((util.normaljoin(dir, found) for found in globpattern(fspath, leaf)))
  
      return r
function_tokens: def glob ( fsdir , path ) : dir , leaf = os . path . split ( path ) if dir == '' : return globpattern ( fsdir , leaf ) if hasglob ( dir ) : dirsfound = glob ( fsdir , dir ) else : dirsfound = [ dir ] r = [ ] for dir in dirsfound : fspath = util . normaljoin ( fsdir , dir ) if not os . path . isdir ( fspath ) : continue r . extend ( ( util . normaljoin ( dir , found ) for found in globpattern ( fspath , leaf ) ) ) return r