homebridge-melcloud-control 4.4.1-beta.14 → 4.4.1-beta.16
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/package.json +1 -1
- package/src/functions.js +9 -5
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"displayName": "MELCloud Control",
|
|
3
3
|
"name": "homebridge-melcloud-control",
|
|
4
|
-
"version": "4.4.1-beta.
|
|
4
|
+
"version": "4.4.1-beta.16",
|
|
5
5
|
"description": "Homebridge plugin to control Mitsubishi Air Conditioner, Heat Pump and Energy Recovery Ventilation.",
|
|
6
6
|
"license": "MIT",
|
|
7
7
|
"author": "grzegorz914",
|
package/src/functions.js
CHANGED
|
@@ -98,6 +98,7 @@ class Functions extends EventEmitter {
|
|
|
98
98
|
return result;
|
|
99
99
|
} catch { }
|
|
100
100
|
}
|
|
101
|
+
return result;
|
|
101
102
|
}
|
|
102
103
|
|
|
103
104
|
/* ===================== QNAP ===================== */
|
|
@@ -125,13 +126,13 @@ class Functions extends EventEmitter {
|
|
|
125
126
|
return result;
|
|
126
127
|
} catch { }
|
|
127
128
|
}
|
|
129
|
+
return result;
|
|
128
130
|
}
|
|
129
131
|
|
|
130
132
|
/* ===================== Linux ARM ===================== */
|
|
131
133
|
if (isLinux && isARM) {
|
|
132
134
|
const armCandidates = ['/usr/bin/chromium-browser', '/usr/bin/chromium', '/snap/bin/chromium'];
|
|
133
135
|
|
|
134
|
-
// 1. Sprawdź istniejące
|
|
135
136
|
for (const path of armCandidates) {
|
|
136
137
|
try {
|
|
137
138
|
await access(path, fs.constants.X_OK);
|
|
@@ -140,16 +141,18 @@ class Functions extends EventEmitter {
|
|
|
140
141
|
} catch { }
|
|
141
142
|
}
|
|
142
143
|
|
|
143
|
-
// 2. Zainstaluj jeśli nie Docker
|
|
144
144
|
if (!isDocker) {
|
|
145
145
|
try {
|
|
146
|
+
this.emit('debug', `Try install chromium`);
|
|
146
147
|
await execPromise('sudo apt-get update -y');
|
|
147
|
-
await execPromise('sudo apt-get install -y chromium
|
|
148
|
+
await execPromise('sudo apt-get install -y chromium || true');
|
|
149
|
+
await execPromise('sudo apt-get install -y chromium-browser chromium-codecs-ffmpeg || true');
|
|
148
150
|
await execPromise('sudo apt-get install -y libnspr4 libnss3 libx11-6 libxcomposite1 libxdamage1 libxrandr2 libatk1.0-0 libcups2 libdrm2 libgbm1 libasound2 || true');
|
|
149
|
-
} catch {
|
|
151
|
+
} catch (error) {
|
|
152
|
+
this.emit('debug', `Install chromium failed ${error}`);
|
|
153
|
+
}
|
|
150
154
|
}
|
|
151
155
|
|
|
152
|
-
// 3. Retry po instalacji
|
|
153
156
|
for (const path of armCandidates) {
|
|
154
157
|
try {
|
|
155
158
|
await access(path, fs.constants.X_OK);
|
|
@@ -157,6 +160,7 @@ class Functions extends EventEmitter {
|
|
|
157
160
|
return result;
|
|
158
161
|
} catch { }
|
|
159
162
|
}
|
|
163
|
+
return result;
|
|
160
164
|
}
|
|
161
165
|
|
|
162
166
|
/* ===================== Linux x64 ===================== */
|