code: def is_excluded(root, excludes):
      # type: (unicode, List[unicode]) -> bool
      
      for exclude in excludes:
          if fnmatch(root, exclude):
              return True
      return False
docs: Check if the directory is in the exclude list.
  
      Note: by having trailing slashes, we avoid common prefix issues, like
            e.g. an exlude "foo" also accidentally excluding "foobar".