Skip to content
Snippets Groups Projects
Commit d0094d8b authored by Markus Reiter's avatar Markus Reiter
Browse files

Add `GITHUB_FORK_ALLOWLIST`.

parent 7bd2f511
No related branches found
No related tags found
No related merge requests found
......@@ -96,12 +96,19 @@ module SharedAudits
"#{tag} is a GitLab pre-release."
end
GITHUB_FORK_ALLOWLIST = %w[
variar/klogg
].freeze
def github(user, repo)
metadata = github_repo_data(user, repo)
return if metadata.nil?
return "GitHub fork (not canonical repository)" if metadata["fork"]
if metadata["fork"] && !GITHUB_FORK_ALLOWLIST.include?("#{user}/#{repo}")
return "GitHub fork (not canonical repository)"
end
if (metadata["forks_count"] < 30) && (metadata["subscribers_count"] < 30) &&
(metadata["stargazers_count"] < 75)
return "GitHub repository not notable enough (<30 forks, <30 watchers and <75 stars)"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment