Skip to content

Commit

Permalink
Update PRs readme
Browse files Browse the repository at this point in the history
  • Loading branch information
LinuxJedi committed Aug 11, 2023
1 parent a8ab5d6 commit e0cf0f2
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions pull-requests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,20 @@ To execute this you will need a GitHub token from https://github.com/settings/to
./get_prs.py 2022-W1 2022-W52
```

You can also add `-v` to the command line parameters to verbosely output the progress

### report.py

This generates a list of pull requets that require attention. Options are:

* `-r` - report type, `old` gets the pull requests sorted by oldest first, `new` gets the pull requests sorted by newest first. This is a required parameter.
* `-d` - days, the minimum number of days since last action to add the PR to the report. Default is `7`.
* `-l` - limit, the maxiumu number of items to add to the final output report. Default is `30`. `0` means unlimited.
* `-s` - sort order, `longest` sorts the final output by the longest time since the last response, `shortest` sorts by the shortest time since the last response. By default it will be unsorted, so ordered by the report type option.
* `-v` - verbose, add verbose output to the console.

As with `get_prs.py`, you will require the `GITHUB_TOKEN` environment variable.

### plot_prs.py

This plots the new open/closed statuses for each week, using data from a CSV file. It requires `matplotlib` and `numpy` Python packages are installed (both in standard distro packages and PyPi). It requires you to provied the CSV file as a parameter and generates the file `prs.png` as an output. As an example you would execute it using:
Expand All @@ -25,3 +39,4 @@ This plots the total count of open/closed PRs for each week using the data from
```
./plot_totals.py prs-2022-W1..2022-W52.csv
```

0 comments on commit e0cf0f2

Please sign in to comment.