-
Notifications
You must be signed in to change notification settings - Fork 9
36 lines (32 loc) · 941 Bytes
/
daff.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: Generate Daff
on:
pull_request:
paths:
- 'Spreadsheet/**'
jobs:
comment-diff:
runs-on: ubuntu-20.04
defaults:
run:
# The following allows for each run step to utilize ~/.bash_profile
# for setting up the per-step initial state.
# --login: a login shell. Source ~/.bash_profile
# -e: exit on first error
# -o pipefail: piped processes are important; fail if they fail
shell: bash --login -eo pipefail {0}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: install requirements
run: |
pip install --upgrade pip
pip install daff
- name: daff diff
env:
GH_TOKEN: ${{ github.token }}
GH_REPO: ${{ github.repository }}
PRNUM: ${{ github.event.pull_request.number }}
run: |
daff git csv
gh pr comment $PRNUM --body-file <(git diff Spreadsheet/)