From 57eb54d20efa9a82c13aadb20aa871aef97ca025 Mon Sep 17 00:00:00 2001 From: 839 <8398a7@gmail.com> Date: Fri, 26 Jun 2020 12:25:13 +0900 Subject: [PATCH] Add execution state information (#499) * Add execution state information (#371) * Type conformance to REST API (#371) * Changed to get the job name (#371) --- src/context.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/context.ts b/src/context.ts index 21f14c9..52efabb 100644 --- a/src/context.ts +++ b/src/context.ts @@ -15,6 +15,9 @@ export class Context { workflow: string action: string actor: string + job: string + runNumber: number + runId: number /** * Hydrate the context from the environment @@ -37,6 +40,9 @@ export class Context { this.workflow = process.env.GITHUB_WORKFLOW as string this.action = process.env.GITHUB_ACTION as string this.actor = process.env.GITHUB_ACTOR as string + this.job = process.env.GITHUB_JOB as string + this.runNumber = parseInt(process.env.GITHUB_RUN_NUMBER as string, 10) + this.runId = parseInt(process.env.GITHUB_RUN_ID as string, 10) } get issue(): {owner: string; repo: string; number: number} {