Search Get full file list
11644
function getFileList(branchName = config.baseBranch) {
  logger.debug(`getFileList(${branchName})`);
  return config.storage.getFileList(branchName);
}
484854
def get_file_list(self, lstPaths, lstXtn, lstExcluded, VERBOSE = False):
        
        if VERBOSE:
            print("Generating list of Files...")
            print("Paths = ", lstPaths)
            print("Xtns  = ", lstXtn)
            print("exclude = ", lstExcluded)
        numFiles = 0
        self.filelist = []
        self.fl_metadata = []
        for rootPath in lstPaths:
            if VERBOSE:
                print(rootPath)
            for root, dirs, files in os.walk(rootPath):
                if VERBOSE:
                    print(dirs)
                for basename in files:
                    for xtn in lstXtn:
                        if fnmatch.fnmatch(basename, xtn):
                            filename = os.path.join(root, basename)
                            includeThisFile = "Y"
                            if len(lstExcluded) > 0:
                                for exclude in lstExcluded:
                                    if filename.find(exclude) != -1:
                                        includeThisFile = "N"
                            if includeThisFile == "Y":
                                numFiles = numFiles + 1
                                self.filelist.append(filename)
                                self.add_file_metadata(filename)    # not sure why there is a 2nd list, but there is.

        if VERBOSE:
            print("Found ", numFiles, " files")
        return self.filelist
1196212
def file_list(self, page_size: int, fields: str, order_by: str, query: str) -> dict:
        
        service = self.__get_service()
        results = service.files().list(
            pageSize=page_size,
            fields=fields,
            orderBy=order_by,
            q=query
        ).execute()
        return results.get('files', [])
395873
def get_files(directory, recursive=False):
    """"""
    files_out = []
    if recursive:
        for root, dirs, files in os.walk(os.path.abspath(directory)):
            files = [os.path.join(root, f) for f in files]
            files_out.append(files)
        files_out = list(itertools.chain(*files_out))
    else:
        files_out = [os.path.join(directory, f) for f in os.listdir(directory)]
        files_out = list(filter(lambda f: os.path.isfile(f), files_out))

    # order alphabetically on file name
    return sorted(files_out)
216369
def get_file_list(self):
        
        if os.path.isdir(self.root_path):
            return [os.path.join(self.root_path, f) for f in os.listdir(self.root_path)
                    if os.path.isfile(os.path.join(self.root_path, f))]
        else:
            return [self.root_path]
288066
def get_file_list(wildcard):
    
    files = glob.glob(os.path.expanduser(wildcard))
    return files
1194294
def file_list(load):
    '''
    
    '''
    if 'env' in load:
        # "env" is not supported; Use "saltenv".
        load.pop('env')

    ret = []

    if 'saltenv' not in load:
        return ret

    saltenv = load['saltenv']
    metadata = _init()

    if not metadata or saltenv not in metadata:
        return ret
    for bucket in _find_files(metadata[saltenv]):
        for buckets in six.itervalues(bucket):
            files = [f for f in buckets if not fs.is_file_ignored(__opts__, f)]
            ret += _trim_env_off_path(files, saltenv)

    return ret
335890
def search(path, query, start=0, max_results=100, mode='filename')
      resp = request('/files/search', path: path, query: query, start: start,
        max_results: max_results, mode: mode)
      matches = resp['matches'].map { |m| parse_tagged_response(m['metadata']) }
      return matches
    end
1329468
def getCompleteFile(self, basepath):
        """"""
        dirname = getDirname(self.getName())
        return os.path.join(basepath, dirname, "complete.txt")
755236
def file_list(self, load):
        '''
        
        '''
        if 'env' in load:
            # "env" is not supported; Use "saltenv".
            load.pop('env')

        ret = set()
        if 'saltenv' not in load:
            return []
        if not isinstance(load['saltenv'], six.string_types):
            load['saltenv'] = six.text_type(load['saltenv'])

        for fsb in self.backends(load.pop('fsbackend', None)):
            fstr = '{0}.file_list'.format(fsb)
            if fstr in self.servers:
                ret.update(self.servers[fstr](load))
        # some *fs do not handle prefix. Ensure it is filtered
        prefix = load.get('prefix', '').strip('/')
        if prefix != '':
            ret = [f for f in ret if f.startswith(prefix)]
        return sorted(ret)
812525
def files(self, absolute=False):
        """"""

        _paths = []

        for arg in self.all:
            for path in _expand_path(arg):
                if os.path.exists(path):
                    if absolute:
                        _paths.append(os.path.abspath(path))
                    else:
                        _paths.append(path)

        return _paths
1291998
function getNumMatches(fileList, queryExpr) {
    var i,
        matches = 0;
    for (i = 0; i < fileList.length; i++) {
        var temp = countNumMatches(getFileContentsForFile(fileList[i]), queryExpr);
        if (temp) {
            numFiles++;
            matches += temp;
        }
        if (matches > MAX_TOTAL_RESULTS) {
            exceedsMaximum = true;
            break;
        }
    }
    return matches;
}
969157
def _get_file_list(self, working_dir, file_regex=re.compile(r'.*'), ftp=None):
        

        if ftp is None:
            ftp = ftplib.FTP(BGEE_FTP)
            ftp.login("anonymous", "info@monarchinitiative.org")

        working_dir = "{}{}".format(self.version, working_dir)
        LOG.info('Looking for remote files in %s', working_dir)

        ftp.cwd(working_dir)
        remote_files = ftp.nlst()

        # LOG.info('All remote files \n%s', '\n'.join(remote_files))
        files_to_download = [
            dnload for dnload in remote_files if re.match(file_regex, dnload) and
            re.findall(r'^\d+', dnload)[0] in self.tax_ids]
        # LOG.info('Choosing remote files \n%s', '\n'.join(list(files_to_download)))

        return files_to_download, ftp
1229065
def list_attachments(fullname):
    
    parent, filename = os.path.split(fullname)
    filename_without_ext, ext = os.path.splitext(filename)
    attachments = []
    for found_filename in os.listdir(parent):
        found_filename_without_ext, _ = os.path.splitext(found_filename)
        if filename_without_ext == found_filename_without_ext and found_filename != filename:
            attachments.append(os.path.join(parent, found_filename))
    return attachments
13359
def list_files_in_directory(full_directory_path):
    
    files = list()
    for file_name in __os.listdir(full_directory_path):
        if __os.path.isfile(__os.path.join(full_directory_path, file_name)):
            files.append(file_name)
    return files
782784
def _get_all_files(self, path, *exclude):
        '''
        
        '''
        files = list()
        dirs = list()
        links = list()

        if os.access(path, os.R_OK):
            for obj in os.listdir(path):
                obj = os.path.join(path, obj)
                valid = True
                for ex_obj in exclude:
                    if obj.startswith(str(ex_obj)):
                        valid = False
                        continue
                if not valid or not os.path.exists(obj) or not os.access(obj, os.R_OK):
                    continue
                if salt.utils.path.islink(obj):
                    links.append(obj)
                elif os.path.isdir(obj):
                    dirs.append(obj)
                    f_obj, d_obj, l_obj = self._get_all_files(obj, *exclude)
                    files.extend(f_obj)
                    dirs.extend(d_obj)
                    links.extend(l_obj)
                elif os.path.isfile(obj):
                    files.append(obj)

        return sorted(files), sorted(dirs), sorted(links)
947253
def full_file_list(scan_path):
    
    file_list = []
    path = os.path.abspath(scan_path)
    for root, dirs, files in os.walk(path):
        if len(files) != 0 and not '.svn' in root and not '.git' in root:
            for f in files:
                file_list.append(os.path.join(root, f))
    return file_list