-
Notifications
You must be signed in to change notification settings - Fork 9
30 lines (28 loc) · 1.04 KB
/
pr-comment-diff.yaml
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
name: Add comment with diff for PR
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
pull_request:
paths:
- charts/**
branches-ignore:
- release-please--branches--main--components-**
jobs:
getChangedChart:
uses: ./.github/workflows/get-changed-chart.yaml
with:
pr_number: ${{ github.event.pull_request.number }}
postDiffComment:
runs-on: ubuntu-latest
needs: getChangedChart
env:
CT_TARGET_BRANCH: ${{ github.event.pull_request.base.ref || github.event.repository.default_branch }}
GITHUB_TOKEN: ${{ secrets.ACTIONS_BOT_TOKEN }}
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- run: pip install yq
- name: Install sponge
run: sudo apt-get -yq install moreutils
- run: ./.github/scripts/prepare-values.sh "charts/${{ needs.getChangedChart.outputs.chart }}"
- run: ./.github/scripts/create-values-diff.sh ${{ github.event.number }} "charts/${{ needs.getChangedChart.outputs.chart }}"