srggrs / assign-one-project-github-action

Automatically add an issue or pull request to specific GitHub Project(s) when you create and/or label them.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Feature] Assign issues that have a milestone

GRBurst opened this issue · comments

Hey there,

is it possible to link milestones to projects, e.g. assigning all issues of a milestone "A" to the provided project? Similar like labels work. I know that I will have to update the action every time I create a new milestone, but that would be fine for me.

Additionally, it would be nice if I can just define that all issues that are assigned to a milestone should be added to the project.

Happy to hear from you 🎉

Just found out that this already works, it is just not mentioned in the Readme.

I can simply run:

name: Auto Assign Milestoned Issues to Project(s)

on:
  issues:
    types: [milestoned]
env:
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

jobs:
  assign_one_project:
    runs-on: ubuntu-latest
    name: Assign to MY Project
    steps:
    - name: Assign NEW issues and NEW pull requests to MY project
      uses: srggrs/assign-one-project-github-action@1.2.0
      with:
        project: 'https://github.com/owner/repo/projects/1'