1
- name : Node-CI Beta
1
+ name : Beta Release
2
2
3
3
on :
4
4
push :
5
5
branches : [beta-*.*.*, beta]
6
- release :
7
- types : [prereleased]
8
6
workflow_dispatch :
9
7
10
8
jobs :
11
9
build_and_test :
12
- uses : donavanbecker /.github/.github/workflows/nodejs-build-and-test.yml@latest
10
+ uses : homebridge /.github/.github/workflows/nodejs-build-and-test.yml@latest
13
11
with :
14
- enable_coverage : true
12
+ enable_coverage : false
15
13
secrets :
16
14
token : ${{ secrets.GITHUB_TOKEN }}
17
15
lint :
18
16
needs : build_and_test
19
- uses : donavanbecker /.github/.github/workflows/eslint.yml@latest
17
+ uses : homebridge /.github/.github/workflows/eslint.yml@latest
20
18
21
19
publish :
22
20
needs : lint
23
-
24
- if : ${{ github.repository == 'donavanbecker/homebridge-august' }}
25
-
26
- uses : donavanbecker /.github/.github/workflows/npm-publish.yml@latest
21
+ if : ${{ github.repository == 'homebridge-plugins/homebridge-august' }}
22
+ permissions :
23
+ id-token : write
24
+ uses : homebridge /.github/.github/workflows/npm-publish-esm .yml@latest
27
25
with :
28
26
tag : ' beta'
29
27
dynamically_adjust_version : true
@@ -32,14 +30,26 @@ jobs:
32
30
secrets :
33
31
npm_auth_token : ${{ secrets.npm_token }}
34
32
35
- github-releases-to-discord :
33
+ pre-release :
36
34
needs : publish
35
+ if : ${{ github.repository == 'homebridge-plugins/homebridge-august' }}
36
+ uses : homebridge/.github/.github/workflows/pre-release.yml@latest
37
+ with :
38
+ npm_version : ${{ needs.publish.outputs.NPM_VERSION }}
39
+ body : |
40
+ **Beta Release**
41
+ **Version**: v${{ needs.publish.outputs.NPM_VERSION }}
42
+ [How To Test Beta Releases](https://github.com/homebridge-plugins/homebridge-august/wiki/Beta-Version)
37
43
38
- if : ${{ github.repository == 'donavanbecker/homebridge-august' && github.event.release.prerelease == true }}
39
-
40
- uses : OpenWonderLabs/.github/.github/workflows/discord-webhooks.yml@latest
44
+ github-releases-to-discord :
45
+ name : Discord Webhooks
46
+ needs : [build_and_test,publish]
47
+ if : ${{ github.repository == 'homebridge-plugins/homebridge-august' }}
48
+ uses : homebridge/.github/.github/workflows/discord-webhooks.yml@latest
41
49
with :
42
- footer_title : " August"
50
+ title : " August Beta Release"
51
+ description : |
52
+ Version `v${{ needs.publish.outputs.NPM_VERSION }}`
53
+ url : " https://github.com/homebridge-plugins/homebridge-august/releases/tag/v${{ needs.publish.outputs.NPM_VERSION }}"
43
54
secrets :
44
- DISCORD_WEBHOOK_URL_LATEST : ${{ secrets.DISCORD_WEBHOOK_URL_LATEST }}
45
- DISCORD_WEBHOOK_URL_BETA : ${{ secrets.DISCORD_WEBHOOK_URL_BETA }}
55
+ DISCORD_WEBHOOK : ${{ secrets.DISCORD_WEBHOOK_URL_BETA || secrets.DISCORD_WEBHOOK_URL_LATEST }}
0 commit comments