Open
Conversation
Author
|
@eric-Grunt @Resonance1584 Hello! Found you as reviewers in recent PRs. Do you know whom I can ask to review this? |
Resonance1584
left a comment
There was a problem hiding this comment.
Hi @soar - thanks for your contributions. This looks good overall, please respond to my questions inline in the review to see if we can reduce some duplicated logic.
Please also take a look at select-repos_test.go and see if you can add some test logic to validate the new select logic.
| } | ||
|
|
||
| // getReposBySearch uses GitHub's search API to find repositories matching the given query | ||
| func getReposBySearch(config *config.GitXargsConfig) ([]*github.Repository, error) { |
There was a problem hiding this comment.
Can we eliminate this function and call getReposByIntersection etc directly from select-repos?
|
|
||
| case GithubRepositorySearch: | ||
| // If githubRepositorySearch is set, use the GitHub Search API to find matching repositories | ||
| reposFetchedFromSearch, err := getReposBySearch(config) |
There was a problem hiding this comment.
See above - can we call getReposByRepositorySearch directly?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Add GitHub Search API to filter repositories before processing
The repository scope can be narrowed down by using the GitHub Search API. This allows you to select repositories based on various criteria, such as language, topics, or other metadata or file content.
--github-repository-searchto select repositories based on the GitHub Repository Search API--github-code-searchto select repositories based on the GitHub Code Search API--github-orgstill can be used, it will addorg:<name>to the search queryIf both,
--github-repository-searchand--github-code-searchare provided, the repositories will be filtered by both criteria.TODOs
Read the Gruntwork contribution guidelines.
Release Notes (draft)
Added GitHub Search API
Migration Guide