Skip to content

Commit

Permalink
chore: debug tests
Browse files Browse the repository at this point in the history
  • Loading branch information
gentlementlegen committed Jul 17, 2024
1 parent 9bf2cc1 commit 1af81e5
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/action.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ import { envSchema, envValidator, PluginInputs, pluginSettingsSchema, pluginSett
export async function run() {
const payload = github.context.payload.inputs;

console.log("1.", process.env);
payload.env = { ...(payload.env || {}), workflowName: github.context.workflow };
if (!envValidator.test(payload.env)) {
const errors: string[] = [];
Expand Down Expand Up @@ -44,11 +43,10 @@ export async function run() {

await plugin(inputs, env);

return await returnDataToKernel(process.env.GITHUB_TOKEN, inputs.stateId, {});
return returnDataToKernel(process.env.GITHUB_TOKEN, inputs.stateId, {});
}

export async function returnDataToKernel(repoToken: string, stateId: string, output: object) {
console.log("4.", repoToken, stateId, output);
async function returnDataToKernel(repoToken: string, stateId: string, output: object) {
const octokit = new Octokit({ auth: repoToken });
return octokit.repos.createDispatchEvent({
owner: github.context.repo.owner,
Expand Down

0 comments on commit 1af81e5

Please sign in to comment.