Skip to content

Commit

Permalink
Added octokit parser
Browse files Browse the repository at this point in the history
  • Loading branch information
nbhoski committed Jun 13, 2024
1 parent 6ae77af commit d0e5483
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/buildSummary.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ export async function processAndDisplayBuildSummary() {
}

export function getWorkflowStepNames() {
const repository = process.env.GITHUB_REPOSITORY;
const [owner, repo] = repository.split('/');
//const repository = process.env.GITHUB_REPOSITORY;
const [owner, repo] = process.env.GITHUB_REPOSITORY.split('/');
const runId = process.env.GITHUB_RUN_ID
getWorkflowRunJobs(owner as string, repo as string, runId as string);
}
Expand All @@ -106,10 +106,10 @@ export async function getWorkflowRunJobs(owner: string, repo: string, runId: str
// Iterate over the jobs and log the step names
const jobs = response.data.jobs;
jobs.forEach((job as string) => {
console.log(`Job: ${job.name}`)
console.log(`Job: ${job.name}`),
job.steps.forEach((step as string) => {
console.log(` **Step: ${step.name}`)
console.log(` **Uses: ${step.uses}`)
console.log(` **Step: ${step.name}`),
console.log(` **Uses: ${step.uses}`),
});
});
} catch (error) {
Expand Down

0 comments on commit d0e5483

Please sign in to comment.