Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Automatically add issues/PR to a project board based on a GitHub query #9925
One missing feature of GitHub's project boards is the ability to automatically add issues/PRs to a project board based on a GitHub search query.
Two examples of how this would be useful:
would automatically be added to https://github.com/kubernetes-sigs/architecture-tracking/projects/2
would automatically be added to https://github.com/kubernetes-sigs/architecture-tracking/projects/3
We'd probably only want to respond to label add or issue/PR open events rather than poll on a cron, because we'd want the ability to manually remove from a project board if it doesn't apply. But the thought is if we add a framework that we can configure with query = project card create, then we could reuse it in a lot of different places.
cc: @jdumars @bgrant0607 @spiffxp @dims
Hi! I've started on a solution to this and have something working which I'm going to tidy up and submit a PR for.
I plan to store the projects and associated queries in the
I'm quite new to this project, Kubernetes and Go so any advice or feedback is appreciated! Thanks!
Also, I would suggest writing a design document either as a pull request to test-infra or as a Google doc that you can share with firstname.lastname@example.org. I think there are a lot of potential open questions here:
Often it's best to try to get answers to these questions before code is written so you don't have to re-write code in the future.
I'll check the Tide config and can change the keys. At the moment I have designed it as a plugin and it responds to PR open, close, reopen, add label and remove label events.
I'll enquire more about issues before getting started in future. I just started writing it as a way to learn about this project and practise writing Go, so I wasn't sure if I'd be able to make it work and I'm not too worried about it having been unnecessary in this case.
How would I go about providing a design document as a pull request? Would that just be an 'empty' pull request with the design proposal in the description?
@wwwil a markdown file could work - however if you have most of the code already written it may not make the most sense. Maybe open the PR when you're ready and we can hash out some ideas there, or comment on this issue and we could do it here.
My two largest questions are:
referenced this issue
Dec 10, 2018
I've submitted a pull request for what I have so far. I hope it make's sense, I'm quite new to this so any feedback is appreciated.
Currently the plugin uses the data in the pull request event so the fields that can be used in a query are limited to the ones the plugin can work with.
As it's responding to pull request events I think that makes it best effort, as it won't add existing pull requests that match the query unless they change.