-
-
Notifications
You must be signed in to change notification settings - Fork 48
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
Add -t option to populate managed modules using GitHub's repository topics #158
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall I do like the feature.
def self.managed_modules(config_file, filter, negative_filter, topic) | ||
if topic | ||
managed_modules = [] | ||
GITHUB.org_repos(GITHUB_ORGANIZATION).each do |repo| |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm wondering if managed_modules = GITHUB.org_repos(GITHUB_ORGANIZATION).filter { |r| r.topics.include?(topic) }.map(&:name)
is easier to read
end | ||
|
||
GITHUB = Octokit::Client.new(:access_token => GITHUB_TOKEN) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure about a global with state. Perhaps it should be a lazy (static) method on the module. This can help in case it's used in an offline context.
Interesting! This sounds like driven by the same idea we had for managing GitLab projects with their projects topics. 👍 See our Python CLI package concierge-cli on PyPI for reference. |
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
This commit renames ModuleSync::PR module to ModuleSync::GitService. Git service classes (ie. GitHub and GitLab) can now be used to implement more features than PR/MR opening. (e.g voxpupuli#158)
GitHub supports tagging repositories with "topics". This PR leverages this functionality to populate a list of managed modules rather than having to manually maintain
managed_modules.yml
.This allows teams to add the topic
ruby
to a GitHub repository and then use the-t ruby
option in their Ruby Modulesync CI/CD job to grab all of the repositories to sync.