parameters: (filename, excludes, extensions)
return_statement: return False
docstring: Check if a file should be included in our check
docstring_summary: Check if a file should be included in our check
docstring_tokens: Check if a file should be included in our check
function: def check_file(filename, excludes, extensions):
      """
      Check if a file should be included in our check
      """
      name, ext = os.path.splitext(filename)
  
      if len(ext) > 0 and ext in extensions:
          if len(excludes) == 0:
              return True
  
          for exclude in excludes:
              if exclude in filename:
                  return False
  
          return True
  
      return False
function_tokens: def check_file ( filename , excludes , extensions ) : name , ext = os . path . splitext ( filename ) if len ( ext ) > 0 and ext in extensions : if len ( excludes ) == 0 : return True for exclude in excludes : if exclude in filename : return False return True return False