Hey, I'm looking to start work on
It would be great if you could pin a GitHub repo from one of your organisations, as well as your personal repositories e.g. I'd like to be able to pin this project on my profile
I wouldn't say this is a particularly simple first Rails issue but since it's yours I think you have the other insight to make it happen.
Basically in the controller we have this defined:
@client = Octokit::Client.
new(access_token: current_user.identities.where(provider: "github").last.token)
Octokit is the GitHub Ruby wrapper. It's been around a long time and is well-supported.
From here with @client, we currently call an octokit method to look up repos to display in the settings area.
@client.repositories.each do |repo|
I imagine to add the org repos, it'll be a matter of finding out what octokit has for that. Maybe they have a flattened way of finding all the repos, but I imagine it could be about sort of traveling up and down the object tree to get them. Hopefully it can be done efficiently.
Good luck, we can help with any bumps!
We're a place where coders share, stay up-to-date and grow their careers.
We strive for transparency and don't collect excess data.