Skip to content
This repository was archived by the owner on Nov 17, 2022. It is now read-only.
This repository was archived by the owner on Nov 17, 2022. It is now read-only.

Action assumes "push" events triggered the last workflow run, which is not always true #1

@simondotm

Description

@simondotm

This is a very useful action, however I have a use-case where I'm checking for a workflow run that was triggered by either a workflow_dispatch or workflow_run and the script always returns an empty commit hash, because it's hard coded to check for push events.

Ideally the workflow event type sent to the API can be optionally specified as an action input eg.:

  octokit.actions
    .listWorkflowRuns({
      owner,
      repo,
      workflow_id: core.getInput("workflow_id"),
      status: "success",
      branch: core.getInput("branch"),
      event: core.getInput("event") || "push",
    })

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions