Skip to content

Commit

Permalink
Merge pull request #10 from mrthankyou/prevent_forked_repos
Browse files Browse the repository at this point in the history
Add fork:false to Github queries
  • Loading branch information
JLLeitschuh authored Feb 22, 2021
2 parents 00273ac + d26d6b1 commit 4cbdb21
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion follow_repos_by_search_term.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def find_and_save_projects_to_lgtm(language: str, search_term: str):
site = LGTMSite.create_from_file()

for date_range in utils.github_dates.generate_dates():
repos = github.search_repositories(query=f'language:{language} created:{date_range} {search_term}')
repos = github.search_repositories(query=f'language:{language} fork:false created:{date_range} {search_term}')

for repo in repos:
# Github has rate limiting in place hence why we add a sleep here. More info can be found here:
Expand Down
2 changes: 1 addition & 1 deletion follow_top_repos_by_star_count.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def find_and_save_projects_to_lgtm(language: str):
site = LGTMSite.create_from_file()

for date_range in utils.github_dates.generate_dates():
repos = github.search_repositories(query=f'stars:>500 created:{date_range} sort:stars language:{language}')
repos = github.search_repositories(query=f'stars:>500 created:{date_range} fork:false sort:stars language:{language}')

for repo in repos:
# Github has rate limiting in place hence why we add a sleep here. More info can be found here:
Expand Down

0 comments on commit 4cbdb21

Please sign in to comment.