-
Notifications
You must be signed in to change notification settings - Fork 82
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Automate documentation updates for rust-lang/rust #1673
Conversation
This will require creating a branch named "docs-update" on rust-lang/rust. This also presumes that the GITHUB_TOKEN that triagebot runs with has enough permissions to write to that branch. |
This looks pretty good (just skimmed it, will do a full review later). I'm curious whether it seems viable to move to branch to the fork rustbot already (?) has, that seems like it's hopefully no difference in the code but avoids any pollution of the branches in the main repo and permissions discussion. I'd also love feedback since I know I pushed for this approach - did this seems lightweight compared to GitHub actions? How did the cron support work out (do we need to change the API there or whatever)? |
I wasn't aware that rustbot has a fork. Which repo is that? I think it should be relatively easy to point it there. This was quite a lot more work than using GitHub Actions, only because I needed to rewrite The hardest part was that I had to learn GraphQL. Every time I've tried using it in the past, I gave up as it seemed too complicated. However, I really needed something like |
Oh, sorry. I think we didn't have a fork before but I've now created one (https://github.com/rustbot/rust), that should have write access etc by rustbot pretty easily. Yeah, I hear you on this being more work up front. Hopefully the one-time upfront cost is justified by the long-term benefits I think we get from it, but we'll have to see. Nice to have the improved PR discovery implemented. |
This sets myself as the reviewer for docs submodule updates. Now with rust-lang/triagebot#1673 automating the process, this piece of the puzzle handles the assignment step.
Yea, I'm glad to finally get a chance to dig into GraphQL. It's not so bad once you figure out the basics. I pushed an update that will use rustbot/rust to create the commits. |
Can you also create a |
One thing that I find confusing is how to get the GraphQL query from Rust source code. I can easily generate the Rust boilerplate using cynic code generator but how to do the opposite? What if I want to tweak a current GraphQL query and test it (which is what am I doing to the other GraphQL query in this codebase)? I'm tempted to think that it would be useful to attach somewhere (as rustdoc comment?) a reproducible GraphQL represention of each query in github-graphql/src/lib.rs Opinions? |
That's a good question. Calling Posted #1675 which includes the query I used here. |
@ehuss thanks for the additional patch, very convenient. Also, I didn't know about the |
I will do this later today. |
…k-Simulacrum Assign myself for docs updates This sets myself as the reviewer for docs submodule updates. Now with rust-lang/triagebot#1673 automating the process, this piece of the puzzle handles the assignment step.
Created. |
…Simulacrum Assign myself for docs updates This sets myself as the reviewer for docs submodule updates. Now with rust-lang/triagebot#1673 automating the process, this piece of the puzzle handles the assignment step.
Assign myself for docs updates This sets myself as the reviewer for docs submodule updates. Now with rust-lang/triagebot#1673 automating the process, this piece of the puzzle handles the assignment step.
This adds a scheduled job that will periodically create a PR that updates the documentation submodules on rust-lang/rust. This was previously handled by me manually running a separate tool, and I wanted to set up a cron job to further automate the process.