/*
Return full list of files in your project
167625
function(root) {
    var files;
    var ignored = ['node_modules/', 'bower_components/', 'dist/', 'tmp/', 'blueprints/'];
    files = walkSync(root).filter(function(file){
      return !ignored.map(function(i){
        return file.indexOf(i) !== -1;
      }).reduce(function(total,value){
        // if we have a true value, then don't include
        return total ? total : (value ? value : total);
      });
    });
    return {
      js: filterByExt(files,'.js'),
      hbs: filterByExt(files,'.hbs')
    };
  }
529625
async function filterFiles(files) {
    const clearModule = replace(/^\.\//, '');
    const resources = files | filter(test(/^((icon\.png)|(README(\.\w+)?\.md))$/));
    const missing = without(files, requiredFiles);

    if (missing.length > 0) {
        return reject(Error(`missing ${missing.join(', ')} from the project`));
    }

    if (!contains('icon.png', files)) {
        emitWarning('compiling app without providing an icon.png file');
    }

    const infoFiles = await listFiles('info')
        | filter(test(/[a-z]{2}(_[A-Z]{2,3})?\.md/))
        | map(path.join('info/', _));

    return fs.readFileAsync('index.js', 'utf-8')
        .then(inspect)
        .then(over(lensProp('modules'), filter(startsWith('./'))))
        .then(({ code, modules }) => ({
            code,
            files: union(modules.map(clearModule),
                [...resources, ...requiredFiles, ...infoFiles])
        }));
}
242008
private List<org.jfrog.hudson.pipeline.types.File> getBuildFilesList(Stream<? extends BaseBuildFileBean> buildFilesStream) {
        return buildFilesStream
                .filter(buildFile -> StringUtils.isNotBlank(buildFile.getLocalPath()))
                .filter(buildFile -> StringUtils.isNotBlank(buildFile.getRemotePath()))
                .map(org.jfrog.hudson.pipeline.types.File::new)
                .distinct()
                .collect(Collectors.toList());
    }
39359
def get_files(self, offset=None, limit=None):
        
        params = {'project': self.id, 'offset': offset, 'limit': limit}
        return self._api.files.query(api=self._api, **params)
535219
def get_files():
    
    sources = []
    headers = ["datatable/include/datatable.h"]
    assert os.path.isfile(headers[0])
    for dirpath, _, filenames in os.walk("c"):
        for f in filenames:
            fullname = os.path.join(dirpath, f)
            if f.endswith(".h") or f.endswith(".inc"):
                headers.append(fullname)
            elif f.endswith(".c") or f.endswith(".cc"):
                sources.append(fullname)
    return (sources, headers)
1252609
async function getFileList(dir, fileList) {
  return new Promise(async function (resolve, reject) {  
  fileList = fileList || [];
  var filesIndex = await io.getFiles(dir, null);   
  var files = io.absoluteFiles(filesIndex);
  files.forEach(function (file) {
    fileList.push(file);
  });
  resolve(fileList);
});
}
814985
function collect(){
  let arrOfJsFiles = [];
  let all = {nameToContent: {}, contentToName: {}};
  let files = getFiles();
  for(let file of files){
     if(file.endsWith('.js')){
       arrOfJsFiles.push(file);
     }
     if(file.endsWith('.jsx') || file.endsWith('.html') || file.endsWith('.htm') || file.endsWith('.js')){
       all.nameToContent[file] = fs.readFileSync(file, 'utf-8');
       all.contentToName[all.nameToContent[file]] = file;
     }
  }
  return all;
}
437018
function filesFromFileSet (dirname, fileset) {
  if (!fileset.includes || !fileset.includes.length) {
    return [];
  }
  return fileset.includes
    .filter(include => !glob.hasMagic(include))
    .map(include => path.join(dirname, include));
}
1240487
public String[] getFileList()
    {
        String[] files = null;
        String strFilename = this.getProperty("filename");
        if (strFilename != null)
        {
            files = new String[1];
            files[0] = strFilename;
        }
        String strDirname = this.getProperty("folder");
        if (strDirname != null)
        {
            FileList list = new FileList(strDirname);
            files = list.getFileNames();
            if (!strDirname.endsWith("/"))
                strDirname += "/";
            for (int i = 0; i < files.length; i++)
            {
                files[i] = strDirname + files[i];   // Full pathname
            }
        }
        return files;
    }
782903
async function getPrFiles(prNo) {
  logger.debug(`getPrFiles(${prNo})`);
  if (!prNo) {
    return [];
  }

  // GET /rest/api/1.0/projects/{projectKey}/repos/{repositorySlug}/pull-requests/{pullRequestId}/changes
  const values = await utils.accumulateValues(
    `./rest/api/1.0/projects/${config.projectKey}/repos/${
      config.repositorySlug
    }/pull-requests/${prNo}/changes?withComments=false`
  );
  return values.map(f => f.path.toString);
}
548003
def getoutputfiles(self, loadmetadata=True, client=None,requiremetadata=False):
        """"""
        for outputfilename, outputtemplate in self.outputpairs():
            yield CLAMOutputFile(self.projectpath, outputfilename, loadmetadata,client,requiremetadata), outputtemplate
1039059
function getAllOpenFiles() {
        var result = getWorkingSet(ALL_PANES);
        _.forEach(_panes, function (pane) {
            var file = pane.getCurrentlyViewedFile();
            if (file) {
                result = _.union(result, [file]);
            }
        });
        return result;
    }
815949
def get_project_urls(project):
    """"""
    urls = []
    with ftputil.FTPHost(sra_host, sra_user, sra_password) as ftp_host:
        download_paths = []
        exp_dir = '/sra/sra-instant/reads/ByStudy/sra/SRP/%s/%s/' \
                %(project[:6], project)
        ftp_host.chdir(exp_dir)
        run_folders = ftp_host.listdir(ftp_host.curdir)

        # compile a list of all files
        for folder in run_folders:
            files = ftp_host.listdir(folder)
            assert len(files) == 1
            for f in files:
                path = exp_dir + folder + '/' + f
                urls.append(path)
    return urls
1197718
public List<File> getFiles() {
        List<File> result = new LinkedList<File>();
        for (DataFile dataFile : dataFiles.values()) {
            result.add(dataFile.getFile());
        }
        return result;
    }
787217
function (dir, filelist, ext, currentBundleOptions) {
    var path = path || require('path');
    var fs = fs || require('fs');
    var files = fs.readdirSync(dir);
    filelist = filelist || [];
    files.forEach(function (file) {
        if (fs.statSync(path.join(dir, file)).isDirectory()) {
            filelist = walkSync(path.join(dir, file), filelist, ext, currentBundleOptions);
        }
        else {
            if (file.match(new RegExp("." + ext + "$")) && !isExcluded(file, currentBundleOptions))
                filelist.push(path.join(dir, file));
        }
    });
    return filelist;
}
1009570
function getFolders(dir) {
  try {
    return fs.readdirSync(dir)
      .filter(function (file) {
        return exports.isDirectory(path.join(dir, file));
      });
  } catch (ex) {
    return [];
  }
}
1203446
function getEntitlementFiles(preferences) {
    const files = [];
    const entitlements = path.join(
      preferences.projectRoot,
      "platforms",
      "ios",
      preferences.projectName,
      "Resources",
      `${preferences.projectName}.entitlements`
    );
    files.push(
      path.join(
        preferences.projectRoot,
        "platforms",
        "ios",
        preferences.projectName,
        `${preferences.projectName}.entitlements`
      )
    );
    files.push(entitlements);

    for (let i = 0; i < BUILD_TYPES.length; i++) {
      const buildType = BUILD_TYPES[i];
      const plist = path.join(
        preferences.projectRoot,
        "platforms",
        "ios",
        preferences.projectName,
        `Entitlements-${buildType}.plist`
      );
      files.push(plist);
    }

    return files;
  }