homebridge-securitysystem 7.2.0 → 7.2.1-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/codeql.yml +35 -31
- package/.github/workflows/dependency-review.yml +8 -4
- package/.github/workflows/install-package.yml +6 -2
- package/.github/workflows/new-tag.yml +39 -0
- package/.github/workflows/update-version.yml +4 -2
- package/package.json +1 -1
- package/src/index.js +1 -3
|
@@ -13,12 +13,17 @@ name: "CodeQL"
|
|
|
13
13
|
|
|
14
14
|
on:
|
|
15
15
|
push:
|
|
16
|
-
branches: [
|
|
16
|
+
branches: ["main"]
|
|
17
|
+
paths-ignore:
|
|
18
|
+
- "**.md"
|
|
17
19
|
pull_request:
|
|
20
|
+
types: [opened, reopened, synchronize, ready_for_review]
|
|
18
21
|
# The branches below must be a subset of the branches above
|
|
19
|
-
branches: [
|
|
22
|
+
branches: ["main"]
|
|
23
|
+
paths-ignore:
|
|
24
|
+
- "**.md"
|
|
20
25
|
schedule:
|
|
21
|
-
- cron:
|
|
26
|
+
- cron: "37 23 * * 5"
|
|
22
27
|
|
|
23
28
|
jobs:
|
|
24
29
|
analyze:
|
|
@@ -32,41 +37,40 @@ jobs:
|
|
|
32
37
|
strategy:
|
|
33
38
|
fail-fast: false
|
|
34
39
|
matrix:
|
|
35
|
-
language: [
|
|
40
|
+
language: ["javascript"]
|
|
36
41
|
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
|
|
37
42
|
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
|
|
38
43
|
|
|
39
44
|
steps:
|
|
40
|
-
|
|
41
|
-
|
|
45
|
+
- name: Checkout repository
|
|
46
|
+
uses: actions/checkout@v3
|
|
42
47
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
|
|
53
|
-
# queries: security-extended,security-and-quality
|
|
48
|
+
# Initializes the CodeQL tools for scanning.
|
|
49
|
+
- name: Initialize CodeQL
|
|
50
|
+
uses: github/codeql-action/init@v2
|
|
51
|
+
with:
|
|
52
|
+
languages: ${{ matrix.language }}
|
|
53
|
+
# If you wish to specify custom queries, you can do so here or in a config file.
|
|
54
|
+
# By default, queries listed here will override any specified in a config file.
|
|
55
|
+
# Prefix the list here with "+" to use these queries and those in the config file.
|
|
54
56
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
# If this step fails, then you should remove it and run the build manually (see below)
|
|
58
|
-
- name: Autobuild
|
|
59
|
-
uses: github/codeql-action/autobuild@v2
|
|
57
|
+
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
|
|
58
|
+
# queries: security-extended,security-and-quality
|
|
60
59
|
|
|
61
|
-
|
|
62
|
-
|
|
60
|
+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
|
61
|
+
# If this step fails, then you should remove it and run the build manually (see below)
|
|
62
|
+
- name: Autobuild
|
|
63
|
+
uses: github/codeql-action/autobuild@v2
|
|
63
64
|
|
|
64
|
-
|
|
65
|
-
|
|
65
|
+
# ℹ️ Command-line programs to run using the OS shell.
|
|
66
|
+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
|
|
66
67
|
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
# ./location_of_script_within_repo/buildscript.sh
|
|
68
|
+
# If the Autobuild fails above, remove it and uncomment the following three lines.
|
|
69
|
+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
|
|
70
70
|
|
|
71
|
-
|
|
72
|
-
|
|
71
|
+
# - run: |
|
|
72
|
+
# echo "Run, Build Application using script"
|
|
73
|
+
# ./location_of_script_within_repo/buildscript.sh
|
|
74
|
+
|
|
75
|
+
- name: Perform CodeQL Analysis
|
|
76
|
+
uses: github/codeql-action/analyze@v2
|
|
@@ -4,8 +4,12 @@
|
|
|
4
4
|
#
|
|
5
5
|
# Source repository: https://github.com/actions/dependency-review-action
|
|
6
6
|
# Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement
|
|
7
|
-
name:
|
|
8
|
-
on:
|
|
7
|
+
name: "Dependency Review"
|
|
8
|
+
on:
|
|
9
|
+
pull_request:
|
|
10
|
+
types: [opened, reopened, synchronize, ready_for_review]
|
|
11
|
+
paths-ignore:
|
|
12
|
+
- "**.md"
|
|
9
13
|
|
|
10
14
|
permissions:
|
|
11
15
|
contents: read
|
|
@@ -14,7 +18,7 @@ jobs:
|
|
|
14
18
|
dependency-review:
|
|
15
19
|
runs-on: ubuntu-latest
|
|
16
20
|
steps:
|
|
17
|
-
- name:
|
|
21
|
+
- name: "Checkout Repository"
|
|
18
22
|
uses: actions/checkout@v3
|
|
19
|
-
- name:
|
|
23
|
+
- name: "Dependency Review"
|
|
20
24
|
uses: actions/dependency-review-action@v3
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
name: Create tag
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
types:
|
|
6
|
+
- closed
|
|
7
|
+
branches:
|
|
8
|
+
- main
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
get-tag-name:
|
|
12
|
+
name: Get tag name
|
|
13
|
+
runs-on: ubuntu-latest
|
|
14
|
+
if: github.event.pull_request.merged == true && contains(github.event.pull_request.labels.*.name, 'new-release')
|
|
15
|
+
outputs:
|
|
16
|
+
tag-name: ${{ steps.get-tag-name.outputs.tag-name }}
|
|
17
|
+
steps:
|
|
18
|
+
- name: Get tag name
|
|
19
|
+
id: get-tag-name
|
|
20
|
+
run: |
|
|
21
|
+
branch_name="${{ github.event.pull_request.head.ref }}"
|
|
22
|
+
tag_name=$(echo $branch_name | sed 's/version\///')
|
|
23
|
+
echo "tag-name=$tag_name" >> $GITHUB_OUTPUT
|
|
24
|
+
|
|
25
|
+
create-tag:
|
|
26
|
+
name: Create new tag
|
|
27
|
+
needs: get-tag-name
|
|
28
|
+
runs-on: ubuntu-latest
|
|
29
|
+
if: needs.get-tag-name.outputs.tag-name != ''
|
|
30
|
+
steps:
|
|
31
|
+
- name: Checkout branch
|
|
32
|
+
uses: actions/checkout@v3
|
|
33
|
+
|
|
34
|
+
- name: Create tag name
|
|
35
|
+
run: |
|
|
36
|
+
git tag "${{ needs.get-tag-name.outputs.tag-name }}"
|
|
37
|
+
|
|
38
|
+
- name: Push tag to origin
|
|
39
|
+
run: git push origin "${{ needs.get-tag-name.outputs.tag-name }}"
|
|
@@ -30,7 +30,7 @@ jobs:
|
|
|
30
30
|
uses: actions/checkout@v3
|
|
31
31
|
|
|
32
32
|
- name: Generate tag name
|
|
33
|
-
uses: MiguelRipoll23/generate-tag-name@v1.
|
|
33
|
+
uses: MiguelRipoll23/generate-tag-name@v1.3.0
|
|
34
34
|
id: generate-tag-name
|
|
35
35
|
with:
|
|
36
36
|
channel: ${{ inputs.channel }}
|
|
@@ -47,4 +47,6 @@ jobs:
|
|
|
47
47
|
commit-message: ${{ steps.generate-tag-name.outputs.tag-name }}
|
|
48
48
|
title: Bump version to ${{ steps.generate-tag-name.outputs.tag-name }}
|
|
49
49
|
body: Automated pull request triggered by a new version update.
|
|
50
|
-
labels: ignore-for-release
|
|
50
|
+
labels: new-release,ignore-for-release
|
|
51
|
+
reviewers: MiguelRipoll23
|
|
52
|
+
draft: true
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "homebridge-securitysystem",
|
|
3
3
|
"displayName": "Homebridge Security System",
|
|
4
|
-
"version": "7.2.
|
|
4
|
+
"version": "7.2.1-beta.2",
|
|
5
5
|
"description": "Homebridge plugin that creates a security system accessory that can be triggered by HomeKit sensors.",
|
|
6
6
|
"main": "src/index.js",
|
|
7
7
|
"scripts": {
|
package/src/index.js
CHANGED
|
@@ -154,8 +154,6 @@ function SecuritySystem(log, config) {
|
|
|
154
154
|
.on("get", this.getTargetState.bind(this))
|
|
155
155
|
.on("set", this.setTargetState.bind(this));
|
|
156
156
|
|
|
157
|
-
this.log.info("Security system service (" + options.securitySystemName + ")");
|
|
158
|
-
|
|
159
157
|
this.service.getCharacteristic(
|
|
160
158
|
Characteristic.SecuritySystemCurrentState
|
|
161
159
|
).value = this.currentState;
|
|
@@ -228,7 +226,7 @@ function SecuritySystem(log, config) {
|
|
|
228
226
|
|
|
229
227
|
this.tripOverrideSwitchService = new Service.Switch(
|
|
230
228
|
options.tripOverrideSwitchName,
|
|
231
|
-
"
|
|
229
|
+
"pink-sheep"
|
|
232
230
|
);
|
|
233
231
|
|
|
234
232
|
this.tripOverrideSwitchService.addCharacteristic(
|