Skip to content

Commit

Permalink
Merge pull request #35 from github/items
Browse files Browse the repository at this point in the history
fix: use general term items instead of issues
  • Loading branch information
zkoppert authored Jun 29, 2023
2 parents 5961292 + 744d20e commit 6bd1c13
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,9 +204,9 @@ jobs:
| Average time to first response | 0:50:44.666667 |
| Average time to close | 6 days, 7:08:52 |
| Average time to answer | 1 day |
| Number of issues that remain open | 2 |
| Number of issues closed | 1 |
| Total number of issues created | 3 |
| Number of items that remain open | 2 |
| Number of items closed | 1 |
| Total number of items created | 3 |

| Title | URL | Time to first response | Time to close | Time to answer |
| --- | --- | ---: | ---: | ---: |
Expand Down
8 changes: 4 additions & 4 deletions markdown_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def write_to_markdown(
average_time_to_answer (datetime.timedelta): The average time to answer the discussions.
file (file object, optional): The file object to write to. If not provided,
a file named "issue_metrics.md" will be created.
num_issues_opened (int): The number of issues that remain opened.
num_issues_opened (int): The Number of items that remain opened.
num_issues_closed (int): The number of issues that were closed.
Returns:
Expand All @@ -67,10 +67,10 @@ def write_to_markdown(
)
file.write(f"| Average time to close | {average_time_to_close} |\n")
file.write(f"| Average time to answer | {average_time_to_answer} |\n")
file.write(f"| Number of issues that remain open | {num_issues_opened} |\n")
file.write(f"| Number of issues closed | {num_issues_closed} |\n")
file.write(f"| Number of items that remain open | {num_issues_opened} |\n")
file.write(f"| Number of items closed | {num_issues_closed} |\n")
file.write(
f"| Total number of issues created | {len(issues_with_metrics)} |\n\n"
f"| Total number of items created | {len(issues_with_metrics)} |\n\n"
)
file.write(
"| Title | URL | Time to first response | Time to close | Time to answer |\n"
Expand Down
6 changes: 3 additions & 3 deletions test_markdown_writer.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,9 @@ def test_write_to_markdown(self):
"| Average time to first response | 2 days, 0:00:00 |\n"
"| Average time to close | 3 days, 0:00:00 |\n"
"| Average time to answer | 4 days, 0:00:00 |\n"
"| Number of issues that remain open | 2 |\n"
"| Number of issues closed | 1 |\n"
"| Total number of issues created | 2 |\n\n"
"| Number of items that remain open | 2 |\n"
"| Number of items closed | 1 |\n"
"| Total number of items created | 2 |\n\n"
"| Title | URL | Time to first response | Time to close | Time to answer |\n"
"| --- | --- | ---: | ---: | ---: |\n"
"| Issue 1 | https://github.com/user/repo/issues/1 | 1 day, 0:00:00 | "
Expand Down

0 comments on commit 6bd1c13

Please sign in to comment.