Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/umihico/shibafu
Keep Track of Your PRs in a Spreadsheet
https://github.com/umihico/shibafu
performance-monitoring
Last synced: about 2 months ago
JSON representation
Keep Track of Your PRs in a Spreadsheet
- Host: GitHub
- URL: https://github.com/umihico/shibafu
- Owner: umihico
- License: apache-2.0
- Created: 2023-08-05T01:22:30.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2023-08-07T06:13:26.000Z (over 1 year ago)
- Last Synced: 2024-05-01T14:35:00.699Z (8 months ago)
- Topics: performance-monitoring
- Language: TypeScript
- Homepage: https://docs.google.com/spreadsheets/d/1mEzOIkgXfNzgx6B8mpvB2yvcPVHi5xlwxvPQvmzgY6A
- Size: 107 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Shibafu
Keep Track of Your PRs in a Spreadsheet
## Initial Deploy
Create .env file
```
PROD_DEPLOYMENT_ID=""
DEV_DEPLOYMENT_ID=""
```Run `npm run deploy` and `npm run deploy:prod`. Note the deployment ID and update .env
```
PROD_DEPLOYMENT_ID="-i AKfycbxsIaEhIuMYnrirCt6KxtyoN0CMn0Xpk6kKPqNkWzZBh3r9FU6KPBaBHuaz86UP-6mwpA1"
DEV_DEPLOYMENT_ID="-i AKfycbxsIaEhIuMYnrirCt6KxtyoN0CMn0Xpk6kKPqNkWzZBh3r9FU6KPBaBHuaz86UP-6mwpA2"
```After this, `npm run deploy` and `npm run deploy:prod` will overwrite same deployments, instead of creating new deployment each time.
## Useful Commands
```bash
# Create demo data
PULL=$(gh api -H "Accept: application/vnd.github+json" -H "X-GitHub-Api-Version: 2022-11-28" repos/umihico/docker-selenium-lambda/pulls/176 | jq)# Deploy dev & Run with demo data
npm run deploy && curl -H "Content-Type: application/json" -d $PULL -L "https://script.google.com/macros/s/$DEV_DEPLOYMENT_ID/exec"# Deploy prod & Run with demo data
npm run deploy:prod && curl -H "Content-Type: application/json" -d $PULL -L "https://script.google.com/macros/s/$PROD_DEPLOYMENT_ID/exec"
```## To get all past pull requests per repository
```bash
# gh pr list --base development --limit 10000 --state merged --json number | jq "[. | sort_by(.number) | .[].number] | join(\" \")"
array=( 1 2 3 4 5 )
for i in "${array[@]}"
do
gh api -H "Accept: application/vnd.github+json" -H "X-GitHub-Api-Version: 2022-11-28" repos/umihico/hoge/pulls/${i} > pull_request.json
curl -H "Content-Type: application/json" -d @pull_request.json -L "https://script.google.com/macros/s/${DEPLOYMENT_ID}/exec"
sleep 1
done
```