Giter Site home page Giter Site logo

Comments (7)

galargh avatar galargh commented on July 17, 2024 2

For now I've created a workflow that I run every week (I'll probably put it on cron schedule soon) which:

There's one gotcha though - even though it is possible to add cross org items to Projects (Beta), it is not possible to do so using API :( To work around this, for PRs outside protocol org I create issues like this one https://github.com/protocol/w3dt-stewards/issues/8 and manually add the items listed there to the project.

from .github.

marten-seemann avatar marten-seemann commented on July 17, 2024

Possible solution: The copy workflow creates an issues with a list of all PRs that it opened. The automerge workflow in each repo then edits this list and removes the respective repo from the list after it was executed.
I'm not sure how GitHub deals with concurrent modifications of that list though, we might need to implement some kind of poor-man's mutex here (set a label on the issue to lock the mutex and remove the mutex to unlock?).

from .github.

mvdan avatar mvdan commented on July 17, 2024

Hah, I was thinking of concurrent edit issues, too.

Another idea: set up a GitHub Project titled Deployment <date>, and include an item for every open PR. This seemingly works across repos and orgs too: https://tosbourn.com/github-projects-different-organisations/

You can even use predefined templates for a project like "automated kanban", which uses an issue/PR's status (open, merged, closed, etc) to move it across columns. So then, supposedly, merging or closing a PR would automatically move it out of the "to do" column. I also imagine you could set up custom workflow automation to change this, e.g. have separate columns for "merged" vs "closed", or a column for "merge conficts", etc.

from .github.

marten-seemann avatar marten-seemann commented on July 17, 2024

Good point, GitHub Projects might be the better fit here. Every deployment run would be a new project then.
There's a GitHub Actions workflow that would allow us to automatically assign the PRs (when we create them in the copy workflow?): https://github.com/marketplace/actions/assign-to-one-project

from .github.

marten-seemann avatar marten-seemann commented on July 17, 2024

There's a GitHub Actions workflow that would allow us to automatically assign the PRs (when we create them in the copy workflow?): https://github.com/marketplace/actions/assign-to-one-project

I played around with that Action a bit, and with others I could find on the market place. The problem is that all these actions are used to assign issues / PRs to projects. That's not quite our use case though: We don't want the action to run when a new issue / PR is created (GitHub might not even run the action on initial deployment), but we want the copy workflow to create the project card for the PR it just opened.
We'll probably have to write our on Action for that. Should be a big problem, the code looks pretty straightforward: https://github.com/srggrs/assign-one-project-github-action/blob/42352f30e8f3608e29350741411ab7061c953972/entrypoint.sh#L115-L138

Furthermore, all existing Actions assume that the project already exists. We'll need to create another Action to create a new GitHub Project and export the URL. This will probably require playing around with the GitHub API a bit.

from .github.

marten-seemann avatar marten-seemann commented on July 17, 2024

@BigLep pointed out that we can get this overview over unmerged web3-bot PRs from the Ecosystem Dashboard:
https://ecosystem-research.herokuapp.com/all?range=9999&state=open&user=web3-bot

I'd say this is pretty much exactly what we've been looking for.

from .github.

mvdan avatar mvdan commented on July 17, 2024

@marten-seemann this is likely very relevant to you now: https://github.blog/2021-06-23-introducing-new-github-issues/

In particular, note how you can now create a "super-issue" that has a list of nested issue links, which automatically get checked off as they are closed. I imagine that would be easier than setting up a Project automation.

from .github.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.