Last active
November 27, 2019 15:33
-
-
Save mheadd/069330b271b3152d163569b948885090 to your computer and use it in GitHub Desktop.
Fetch closed issues from a Github repo
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##!/bin/bash | |
## The name of the Github account user or org | |
OWNER=$1 | |
## The name of the repo | |
REPO=$2 | |
## Append the file with listd of issues | |
curl -s "https://api.github.com/repos/$OWNER/$REPO/issues?page=1&per_page=100&state=closed" \ | |
| in2csv -f json \ | |
| csvcut -c 10,11,36,76,78 \ | |
> issues.csv |
Sample output (using mheadd
and civicbot
params:
title,user/login,state,created_at,closed_at
"When flight number not found, exception tossed.",mheadd,closed,2016-03-19T21:12:50+00:00,2016-03-19T21:13:07+00:00
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This script requires that
csvkit
is installed on your computer. If you are on a Mac, try:Once
csvkit
is installed, download the script and make it executable.Execute it by passing in the name of the user org and repo that you want to extract issues from:
The resultant csv file can then be uploaded to Google sheets and sorted by date