mirror of
				https://github.com/esphome/esphome.git
				synced 2025-10-30 22:53:59 +00:00 
			
		
		
		
	Use the github-script action to call the workflow (#4400)
This commit is contained in:
		
							
								
								
									
										26
									
								
								.github/workflows/release.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										26
									
								
								.github/workflows/release.yml
									
									
									
									
										vendored
									
									
								
							| @@ -138,14 +138,18 @@ jobs: | |||||||
|     runs-on: ubuntu-latest |     runs-on: ubuntu-latest | ||||||
|     needs: [deploy-docker] |     needs: [deploy-docker] | ||||||
|     steps: |     steps: | ||||||
|       - env: |       - name: Trigger Workflow | ||||||
|           TOKEN: ${{ secrets.DEPLOY_HA_ADDON_REPO_TOKEN }} |         uses: actions/github-script@v6 | ||||||
|         # yamllint disable rule:line-length |         with: | ||||||
|         run: | |           github-token: ${{ secrets.DEPLOY_HA_ADDON_REPO_TOKEN }} | ||||||
|           curl \ |           script: | | ||||||
|             -u ":$TOKEN" \ |             github.rest.actions.createWorkflowDispatch({ | ||||||
|             -X POST \ |               owner: "esphome", | ||||||
|             -H "Accept: application/vnd.github.v3+json" \ |               repo: "home-assistant-addon", | ||||||
|             https://api.github.com/repos/esphome/home-assistant-addon/actions/workflows/bump-version.yml/dispatches \ |               workflow_id: "bump-version.yml", | ||||||
|             -d '{"ref":"main","inputs":{"version":"${{ github.event.release.tag_name }}","content":${{ toJSON(github.event.release.body) }}}}' |               ref: "main", | ||||||
|         # yamllint enable rule:line-length |               inputs: { | ||||||
|  |                 version: "${{ github.event.release.tag_name }}", | ||||||
|  |                 content: "${{ toJSON(github.event.release.body) }}" | ||||||
|  |               } | ||||||
|  |             }) | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user