-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add workflow job to PR new files into ESPHome (#92)
- Loading branch information
1 parent
93b96bd
commit affdab5
Showing
1 changed file
with
40 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,6 +41,8 @@ jobs: | |
name: Tag and Release | ||
runs-on: ubuntu-latest | ||
needs: build | ||
outputs: | ||
tag: ${{ steps.create_tag.outputs.tag }} | ||
steps: | ||
# Checkout repo, create new git tag, and git release with artifacts | ||
- name: Checkout the repo | ||
|
@@ -67,3 +69,41 @@ jobs: | |
name: Release ${{ steps.create_tag.outputs.tag }} | ||
files: headers/**/*.h | ||
generate_release_notes: true | ||
|
||
esphome-pr: | ||
name: Make PR into ESPHome repo | ||
runs-on: ubuntu-latest | ||
environment: esphome | ||
needs: | ||
- release | ||
steps: | ||
- name: Checkout esphome repo | ||
uses: actions/[email protected] | ||
with: | ||
repository: esphome/esphome | ||
ref: dev | ||
|
||
- name: Download Artifacts | ||
uses: actions/[email protected] | ||
with: | ||
path: /tmp/headers | ||
merge-multiple: true | ||
|
||
- name: Move headers into palce | ||
run: |- | ||
mv /tmp/headers/captive_portal/captive_index.h esphome/components/captive_portal/captive_index.h | ||
mv /tmp/headers/v2/server_index_v2.h esphome/components/web_server/server_index_v2.h | ||
mv /tmp/headers/v3/server_index_v3.h esphome/components/web_server/server_index_v3.h | ||
- name: PR Changes | ||
uses: peter-evans/[email protected] | ||
with: | ||
commit-message: "Update webserver local assets to ${{ needs.release.outputs.tag }}" | ||
committer: esphomebot <[email protected]> | ||
author: esphomebot <[email protected]> | ||
branch: sync/webserver-assets | ||
delete-branch: true | ||
title: "Update webserver local assets to ${{ needs.release.outputs.tag }}" | ||
body-path: .github/PULL_REQUEST_TEMPLATE.md | ||
token: ${{ secrets.ESPHOME_WEBSERVER_SYNC_TOKEN }} | ||
assignees: "@esphome/core" |