Skip to content

Update FSR_QC.csv

Update FSR_QC.csv #70

Workflow file for this run

name: pr_csv_to_md_table
on:
pull_request:
paths:
- 'FSR_QC.csv'
jobs:
build:
name: Comment CSV as Pull-request Table
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Read CSV
id: csv
run: |
git fetch origin $GITHUB_BASE_REF --depth=1
{
echo 'text<<EOF'
echo -n ','
head -1 FSR_QC.csv
git diff origin/$GITHUB_BASE_REF $GITHUB_SHA -U0 -- FSR_QC.csv \
| grep '^[+-][^+-]' \
| sed 's/|/\\|/g' \
| sed 's/^[+-]/&,/'
echo EOF
} >> $GITHUB_OUTPUT
- name: Create MD
uses: petems/[email protected]
id: csv-table-output
with:
csvinput: ${{ steps.csv.outputs.text }}
- uses: mshick/add-pr-comment@v1
with:
message: |
Here are the changes in FSR_QC.csv:
${{steps.csv-table-output.outputs.markdown-table}}
repo-token: ${{ secrets.GITHUB_TOKEN }}
repo-token-user-login: 'github-actions[bot]' # The user.login for temporary GitHub tokens
allow-repeats: true