homebridge-securitysystem 10.0.0-beta.3 → 10.0.0-beta.5

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.
@@ -59,10 +59,75 @@ jobs:
59
59
  generateReleaseNotes: true
60
60
  allowUpdates: true
61
61
 
62
+ update-changelog:
63
+ name: Update changelog
64
+ needs: [create-tag, create-release]
65
+ runs-on: ubuntu-latest
66
+ if: needs.create-tag.outputs.tag-name != ''
67
+ permissions:
68
+ contents: write
69
+ steps:
70
+ - name: Checkout branch
71
+ uses: actions/checkout@v6
72
+ with:
73
+ ref: main
74
+
75
+ - name: Build changelog entry from auto release notes
76
+ env:
77
+ GITHUB_TOKEN: ${{ github.token }}
78
+ TAG_NAME: ${{ needs.create-tag.outputs.tag-name }}
79
+ run: |
80
+ release_notes_text="$(
81
+ gh api \
82
+ repos/${{ github.repository }}/releases/tags/${TAG_NAME} \
83
+ --jq '.body'
84
+ )"
85
+
86
+ if [ -z "${release_notes_text}" ]; then
87
+ echo "Release notes were not generated. Skipping changelog update."
88
+ exit 0
89
+ fi
90
+
91
+ current_date="$(date -u +%F)"
92
+ release_header="## ${TAG_NAME} - ${current_date}"
93
+
94
+ if [ -f CHANGELOG.md ] && grep -Fqx "${release_header}" CHANGELOG.md; then
95
+ echo "Changelog already contains ${release_header}. Skipping changelog update."
96
+ exit 0
97
+ fi
98
+
99
+ temporary_file_path="$(mktemp)"
100
+ {
101
+ echo "# Changelog"
102
+ echo
103
+ echo "${release_header}"
104
+ echo
105
+ echo "${release_notes_text}"
106
+ echo
107
+ if [ -f CHANGELOG.md ]; then
108
+ awk 'NR == 1 && $0 == "# Changelog" { next } { print }' CHANGELOG.md
109
+ fi
110
+ } > "${temporary_file_path}"
111
+
112
+ mv "${temporary_file_path}" CHANGELOG.md
113
+
114
+ - name: Commit changelog
115
+ run: |
116
+ if git diff --quiet CHANGELOG.md; then
117
+ echo "No changelog updates to commit."
118
+ exit 0
119
+ fi
120
+
121
+ git config user.name "github-actions[bot]"
122
+ git config user.email "github-actions[bot]@users.noreply.github.com"
123
+ git add CHANGELOG.md
124
+ git commit -m "docs: update changelog for ${{ needs.create-tag.outputs.tag-name }}"
125
+ git push origin HEAD:main
126
+
62
127
  publish-package:
63
128
  name: Publish package
64
129
  runs-on: ubuntu-latest
65
- needs: [create-tag, create-release]
130
+ needs: [create-tag, create-release, update-changelog]
66
131
 
67
132
  steps:
68
133
  - name: Checkout branch
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "homebridge-securitysystem",
3
3
  "displayName": "Homebridge Security System",
4
4
  "type": "module",
5
- "version": "10.0.0-beta.3",
5
+ "version": "10.0.0-beta.5",
6
6
  "description": "Homebridge plugin that creates a security system accessory that can be triggered by HomeKit sensors.",
7
7
  "author": "MiguelRipoll23",
8
8
  "license": "MIT",
@@ -35,22 +35,22 @@
35
35
  "watch": "npm run build && npm link && nodemon"
36
36
  },
37
37
  "dependencies": {
38
- "@hono/node-server": "^1.19.13",
39
- "hono": "^4.12.12",
38
+ "@hono/node-server": "^1.19.14",
39
+ "hono": "^4.12.14",
40
40
  "node-persist": "^4.0.1"
41
41
  },
42
42
  "devDependencies": {
43
- "@eslint/js": "^9.39.1",
44
- "@types/node": "^24.10.1",
43
+ "@eslint/js": "^10.0.1",
44
+ "@types/node": "^25.6.0",
45
45
  "@types/node-persist": "^3.1.8",
46
- "eslint": "^9.39.1",
47
- "homebridge": "^2.0.0-beta.87",
48
- "nodemon": "^3.1.11",
49
- "rimraf": "^6.1.0",
46
+ "eslint": "^10.2.0",
47
+ "homebridge": "^2.0.0-beta.89",
48
+ "nodemon": "^3.1.14",
49
+ "rimraf": "^6.1.3",
50
50
  "ts-node": "^10.9.2",
51
- "typescript": "^5.9.3",
52
- "typescript-eslint": "^8.46.4",
53
- "vitest": "^3.0.0"
51
+ "typescript": "^6.0.2",
52
+ "typescript-eslint": "^8.58.2",
53
+ "vitest": "^4.1.4"
54
54
  },
55
55
  "funding": [
56
56
  {