@homebridge-eufy-security/eufy-security-client 3.7.2-dev.6 → 3.8.0-dev.7
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/README.md +27 -0
- package/build/eufysecurity.d.ts +2 -0
- package/build/eufysecurity.js +27 -0
- package/build/eufysecurity.js.map +1 -1
- package/build/http/api.d.ts +2 -0
- package/build/http/api.js +39 -6
- package/build/http/api.js.map +1 -1
- package/build/http/device.d.ts +5 -0
- package/build/http/device.js +35 -1
- package/build/http/device.js.map +1 -1
- package/build/http/interfaces.d.ts +1 -0
- package/build/http/station.d.ts +1 -0
- package/build/http/station.js +7 -3
- package/build/http/station.js.map +1 -1
- package/build/http/types.d.ts +4 -0
- package/build/http/types.js +217 -1
- package/build/http/types.js.map +1 -1
- package/build/p2p/interfaces.d.ts +1 -0
- package/build/p2p/session.js +20 -2
- package/build/p2p/session.js.map +1 -1
- package/build/p2p/types.d.ts +1 -0
- package/build/p2p/types.js +1 -0
- package/build/p2p/types.js.map +1 -1
- package/build/p2p/utils.js +1 -0
- package/build/p2p/utils.js.map +1 -1
- package/build/push/service.js +1 -1
- package/build/push/service.js.map +1 -1
- package/coverage/clover.xml +10075 -10031
- package/coverage/coverage-final.json +26 -26
- package/coverage/lcov-report/index.html +59 -59
- package/coverage/lcov.info +16860 -16762
- package/package.json +5 -1
- package/scripts/cut_release.sh +2 -0
- package/scripts/generate_changelog.sh +93 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@homebridge-eufy-security/eufy-security-client",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.8.0-dev.7",
|
|
4
4
|
"description": "Client to communicate with Eufy-Security devices",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "bropat",
|
|
@@ -8,6 +8,10 @@
|
|
|
8
8
|
},
|
|
9
9
|
"homepage": "https://github.com/bropat/eufy-security-client",
|
|
10
10
|
"main": "build/index.js",
|
|
11
|
+
"exports": {
|
|
12
|
+
".": "./build/index.js",
|
|
13
|
+
"./package.json": "./package.json"
|
|
14
|
+
},
|
|
11
15
|
"scripts": {
|
|
12
16
|
"build:ts": "tsc -p tsconfig.build.json && npm run copy-proto-build",
|
|
13
17
|
"copy-proto-build": "npx copyfiles -u 1 \"src/**/*.proto\" \"src/**/*.crt\" build",
|
package/scripts/cut_release.sh
CHANGED
|
@@ -22,9 +22,11 @@ git checkout -b "release/$VERSION" || exit 1
|
|
|
22
22
|
|
|
23
23
|
# Update file
|
|
24
24
|
sed -i 's/version": .*/version": "'$VERSION'",/' package.json
|
|
25
|
+
npm i
|
|
25
26
|
|
|
26
27
|
# Add file to the branch and commit
|
|
27
28
|
git add package.json
|
|
29
|
+
git add package-lock.json
|
|
28
30
|
git commit -m "Add new version"
|
|
29
31
|
|
|
30
32
|
# Push
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
# ==========================================
|
|
3
|
+
# GENERATE CHANGELOG
|
|
4
|
+
# Extracts merged PRs since a given PR number
|
|
5
|
+
# and formats them for the README changelog.
|
|
6
|
+
# ==========================================
|
|
7
|
+
|
|
8
|
+
set -euo pipefail
|
|
9
|
+
|
|
10
|
+
if [ "$#" -ne 1 ]; then
|
|
11
|
+
echo "Usage: $0 <start_pr_number>"
|
|
12
|
+
echo "Example: $0 791"
|
|
13
|
+
echo ""
|
|
14
|
+
echo "Generates changelog entries for all PRs merged after the given PR number."
|
|
15
|
+
exit 1
|
|
16
|
+
fi
|
|
17
|
+
|
|
18
|
+
START_PR=$1
|
|
19
|
+
|
|
20
|
+
if ! command -v gh &> /dev/null; then
|
|
21
|
+
echo "Error: GitHub CLI (gh) is required but not installed."
|
|
22
|
+
exit 1
|
|
23
|
+
fi
|
|
24
|
+
|
|
25
|
+
if ! command -v jq &> /dev/null; then
|
|
26
|
+
echo "Error: jq is required but not installed."
|
|
27
|
+
exit 1
|
|
28
|
+
fi
|
|
29
|
+
|
|
30
|
+
REPO_URL=$(gh repo view --json url -q '.url')
|
|
31
|
+
|
|
32
|
+
# Fetch all merged PRs with number > START_PR
|
|
33
|
+
PRS=$(gh pr list --state merged --limit 100 --json number,title,author,body \
|
|
34
|
+
| jq --argjson start "$START_PR" '[.[] | select(.number > $start)] | sort_by(.number)')
|
|
35
|
+
|
|
36
|
+
if [ "$(echo "$PRS" | jq 'length')" -eq 0 ]; then
|
|
37
|
+
echo "No merged PRs found after #${START_PR}."
|
|
38
|
+
exit 0
|
|
39
|
+
fi
|
|
40
|
+
|
|
41
|
+
FEATURES=""
|
|
42
|
+
FIXES=""
|
|
43
|
+
CHORES=""
|
|
44
|
+
|
|
45
|
+
while IFS= read -r pr; do
|
|
46
|
+
number=$(echo "$pr" | jq -r '.number')
|
|
47
|
+
title=$(echo "$pr" | jq -r '.title')
|
|
48
|
+
author=$(echo "$pr" | jq -r '.author.login')
|
|
49
|
+
lower_title=$(echo "$title" | tr '[:upper:]' '[:lower:]')
|
|
50
|
+
|
|
51
|
+
# Skip merge/sync PRs
|
|
52
|
+
if echo "$lower_title" | grep -qE '^(develop|master|develop > master|master > develop)'; then
|
|
53
|
+
continue
|
|
54
|
+
fi
|
|
55
|
+
|
|
56
|
+
# Skip release PRs
|
|
57
|
+
if echo "$lower_title" | grep -qiE '^release'; then
|
|
58
|
+
continue
|
|
59
|
+
fi
|
|
60
|
+
|
|
61
|
+
# Clean up the title: remove conventional commit prefixes
|
|
62
|
+
clean_title=$(echo "$title" | sed -E 's/^(feat|fix|chore|refactor|docs|test|ci|build|perf|style)(\(.+\))?[!]?:\s*//i')
|
|
63
|
+
# Capitalize first letter
|
|
64
|
+
clean_title="$(echo "${clean_title:0:1}" | tr '[:lower:]' '[:upper:]')${clean_title:1}"
|
|
65
|
+
|
|
66
|
+
url="${REPO_URL}/pull/${number}"
|
|
67
|
+
|
|
68
|
+
# Categorize based on title prefix or content
|
|
69
|
+
if echo "$lower_title" | grep -qiE '^fix|fix:'; then
|
|
70
|
+
FIXES="${FIXES}* Fix: ${clean_title} by @${author} in ${url}\n"
|
|
71
|
+
elif echo "$lower_title" | grep -qiE '^(chore|bump|upgrade|refactor|test|ci|build)'; then
|
|
72
|
+
CHORES="${CHORES}* Chore: ${clean_title} by @${author} in ${url}\n"
|
|
73
|
+
elif echo "$lower_title" | grep -qiE '(add support|add device|new device|feat)'; then
|
|
74
|
+
FEATURES="${FEATURES}* Feature: ${clean_title} by @${author} in ${url}\n"
|
|
75
|
+
elif echo "$lower_title" | grep -qiE '(add|adding|new|support)'; then
|
|
76
|
+
FEATURES="${FEATURES}* Feature: ${clean_title} by @${author} in ${url}\n"
|
|
77
|
+
elif echo "$lower_title" | grep -qiE 'fix'; then
|
|
78
|
+
FIXES="${FIXES}* Fix: ${clean_title} by @${author} in ${url}\n"
|
|
79
|
+
else
|
|
80
|
+
FEATURES="${FEATURES}* Feature: ${clean_title} by @${author} in ${url}\n"
|
|
81
|
+
fi
|
|
82
|
+
done < <(echo "$PRS" | jq -c '.[]')
|
|
83
|
+
|
|
84
|
+
# Print results
|
|
85
|
+
if [ -n "$FEATURES" ]; then
|
|
86
|
+
echo -e "$FEATURES" | sed '/^$/d'
|
|
87
|
+
fi
|
|
88
|
+
if [ -n "$FIXES" ]; then
|
|
89
|
+
echo -e "$FIXES" | sed '/^$/d'
|
|
90
|
+
fi
|
|
91
|
+
if [ -n "$CHORES" ]; then
|
|
92
|
+
echo -e "$CHORES" | sed '/^$/d'
|
|
93
|
+
fi
|