Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Zack Koppert <[email protected]>
  • Loading branch information
anovadox and zkoppert authored Feb 2, 2024
1 parent 2a94f29 commit c26012b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

This project identifies and reports repositories with no activity for configurable amount of time, in order to surface inactive repos to be considered for archival.
The current approach assumes that the repos that you want to evaluate are available in a single GitHub organization.
For the purpose of this action, a repository is considered inactive if it has not had a `push` in a configurable amount of days (can also be configured to determine activity based on default branch).
For the purpose of this action, a repository is considered inactive if it has not had a `push` in a configurable amount of days (can also be configured to determine activity based on default branch. See `ACTIVITY_METHOD` for more details.).

This action was developed by GitHub so that we can keep our open source projects well maintained, and it was made open source in the hopes that it would help you too!
We are actively using and are archiving things in batches since there are many repositories on our report.
Expand Down
2 changes: 1 addition & 1 deletion stale_repos.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def get_active_date(repo):
Returns:
A date object representing the last activity date of the repository.
"""
activity_method = os.getenv("ACTIVITY_METHOD", "pushed")
activity_method = os.getenv("ACTIVITY_METHOD", "pushed").lower()
if activity_method == "default_branch_updated":
commit = repo.branch(repo.default_branch).commit
active_date = parse(commit.commit.as_dict()['committer']['date'])
Expand Down

0 comments on commit c26012b

Please sign in to comment.