Skip to content
Discussion options

You must be logged in to vote

Hey!, I actually ran into this same issue recently
You’re right: unfortunately, github.event.issue.type doesn’t exist (yet). Even though GitHub now supports issue types like “bug” and “task”, those aren’t currently exposed in the GitHub Actions event payload or REST API — at least not in a way we can directly filter on in the workflow.
So the if: github.event.issue.type == 'bug' check won’t work right now.
so you can try :
If you’re using issue forms (YAML templates in .github/ISSUE_TEMPLATE/), you can add a hidden field to store the issue type, like this:
name: Type
id: type
type: hidden
value: bug
Then in your workflow, you can do something like:
if: contains(github.event.issue.body, 'v…

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by chdanielmueller
Comment options

You must be logged in to vote
1 reply
@CollatzConjecture
Comment options

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Actions Build, test, and automate your deployment pipeline with world-class CI/CD Question Ask and answer questions about GitHub features and usage Workflow Configuration Topics about workflow files, YAML setup, job dependencies, and general workflow configuration issues Misc General discussions about GitHub Actions that don't fit other found themes.
4 participants