fp.assign({ owner: item.owner.id }), fp.defaults({ description: '', language: '' }), fp.omitBy(fp.isNil), fp.pick(['id', 'full_name', 'description', 'html_url', 'language', 'stargazers_count']) ])(item)
async function downloadArtifact (toDir, job = {}) { if (F.isNil(job.artifacts) || F.isNil(job.artifacts.url)) { throw new Error(`No artifact found for job - ${job.id}`); } const artifactExt = ARTIFACT_PLATFORM_EXTENSIONS[job.platform] || 'unknown'; const artifactFilepath = path.join(toDir, `app.${artifactExt}`); console.log(`Downloading artifact to ${chalk.underline(artifactFilepath)}`); return await downloadFile(job.artifacts.url, artifactFilepath); }
program .command('url:expo [project-dir]') .description('Prints the expo url for a given project and [optional] release channel') .option('-r, --release-channel [channel]', 'Specify release channel (staging, production, etc)') .action(act(async (dir, { releaseChannel }) => { const { expoState, projectManifest } = await mapProjectDirToExpoInfo(dir); const job = F.head(await fetchArtifactJobs(projectManifest, expoState)); const url = `https://expo.io/${job.fullExperienceName}${F.isNil(releaseChannel) ? '' : `?release-channel=${releaseChannel}`}`; console.log(url); return true; }, true));