-
Notifications
You must be signed in to change notification settings - Fork 36
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
Please add support for Bitbucket Teams #128
Comments
Oh, I think that I forgot to implement part of teams API. 🙇 I try to implement the rest of teams API in next weekend. 💪 |
I released version 1.5.0 😃 This version includes the features what you want. bucket = Tinybucket.new
bucket.teams(role).each do |team|
team.repos.each do |repo|
# Do something with Tinybucket::Model::Repository
puts repo.name
end
end And also you can iterate repositories by projects, like this. ✨ bucket = Tinybucket.new
bucket.teams(role).each do |team|
team.projects.each do |project|
project.repos.each do |repo|
# Do something with Tinybucket::Model::Repository
puts repo.name
end
end
end Check the bitbucket document about Please enjoy version 1.5.0. 👍 |
Looks very good, but now I'm getting a problem iterating through repos. b.teams('admin').each do |team|
team.projects.each do |project|
next unless project.name == 'DevOps'
project.repos.each do |repo|
puts repo
end
end
end gives:
There should be 71 repos listed for this project. |
Oh, Sorry about that. 🙇 I'll investigate. |
Seems to happen for every project with more than 10 repos. It throws the ArgumentError after the tenth repo. |
Thank you for your report 😃 Yes, it looks like a bug on iterating any resource with the specific query params. |
Please try with v1.5.1 which includes the bug fix about your problem. 😃 |
It works perfectly! Thank you so much for this. |
Please add support for Bitbucket Teams (https://developer.atlassian.com/bitbucket/api/2/reference/resource/teams).
Our Bitbucket instance has lots of repos which we organise by Team. I would like to iterate through each project's repos for reports, e.g. number of open pull requests per team.
To do this I'd like to be able to:
The text was updated successfully, but these errors were encountered: