Update handling of dashboard PR genertion to handle file deletions. (#11489)
* Update handling of dashboard PR genertion to handle file deletions. * Pin version properly.
Austin S. Hemmelgarn committed
Sep 15, 2021 at 12:25 UTC
036a661afbdbe24cfce655167a5b90fa1088c6ef
1 file changed
+8
-13
.github/workflows/dashboard-pr.yml
+8
-13
@@ -31,18 +31,13 @@ jobs:
31
- name: Update Files
32
run: |
33
web/gui/bundle_dashboard.py ${{ github.event.inputs.dashboard_version }}
34
- - name: Commit Changes
35
- uses: swinton/commit@v2.x
36
- env:
37
- GH_TOKEN: ${{ secrets.NETDATABOT_GITHUB_TOKEN }}
34
+ - name: Create Pull Request
35
+ uses: peter-evans/create-pull-request@v3
36
with:
39
- files: ${{ env.COMMIT_FILES }} # Created by the bundle_dashboard.py script.
37
+ title: 'Update dashboard to version ${{ github.event.inputs.dashboard_version }}.'
38
+ body: 'See https://github.com/netdata/dashboard/releases/tag/${{ github.event.inputs.dashboard_version }} for changes.'
39
+ branch: dashboard-${{ github.events.inputs.dashboard_version }}
40
+ branch-suffix: timestamp
41
+ delete-branch: true
42
commit-message: 'Update dashboard to version ${{ github.event.inputs.dashboard_version }}.'
41
- ref: refs/heads/dashboard-${{ github.event.inputs.dashboard_version }}
42
- - name: Create PR
43
- uses: repo-sync/pull-request@v2
44
- with:
45
- source_branch: dashboard-${{ github.event.inputs.dashboard_version }}
46
- pr_title: 'Update dashboard to version ${{ github.event.inputs.dashboard_version }}.'
47
- pr_body: 'See https://github.com/netdata/dashboard/releases/tag/${{ github.event.inputs.dashboard_version }} for changes.'
48
- github_token: ${{ secrets.NETDATABOT_GITHUB_TOKEN }}
43
+ token: ${{ secrets.NETDATABOT_GITHUB_TOKEN }}