Skip to content

Commit 0fcd188

Browse files
mastrolinuxumbynosendorama
committed
Change the name of the package (#22)
* Change the name of the package * refactor arduino-cloud to arduino-iot-cloud * rename all missed occurrences of arduinocloud Co-authored-by: Umberto Baldi <34278123+umbynos@users.noreply.github.com> Co-authored-by: Edoardo T <endorama@users.noreply.github.com>
1 parent 9af0343 commit 0fcd188

12 files changed

+506
-498
lines changed

arduino-cloud.html

Lines changed: 0 additions & 437 deletions
This file was deleted.

arduino-iot-client-mqtt/ArduinoCloudError.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
/*
22
* Copyright 2019 ARDUINO SA (http://www.arduino.cc/)
3-
* This file is part of node-red-contrib-arduino-cloud.
3+
* This file is part of node-red-contrib-arduino-iot-cloud.
44
* Copyright (c) 2019
55
*
66
* This software is released under:
77
* The GNU General Public License, which covers the main part of
8-
* node-red-contrib-arduino-cloud
8+
* node-red-contrib-arduino-iot-cloud
99
* The terms of this license can be found at:
1010
* https://www.gnu.org/licenses/gpl-3.0.en.html
1111
*

arduino-iot-client-mqtt/arduino-iot-client-mqtt.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
/*
22
* Copyright 2019 ARDUINO SA (http://www.arduino.cc/)
3-
* This file is part of node-red-contrib-arduino-cloud.
3+
* This file is part of node-red-contrib-arduino-iot-cloud.
44
* Copyright (c) 2019
55
*
66
* This software is released under:
77
* The GNU General Public License, which covers the main part of
8-
* node-red-contrib-arduino-cloud
8+
* node-red-contrib-arduino-iot-cloud
99
* The terms of this license can be found at:
1010
* https://www.gnu.org/licenses/gpl-3.0.en.html
1111
*

arduino-iot-cloud.html

Lines changed: 445 additions & 0 deletions
Large diffs are not rendered by default.

arduino-cloud.js renamed to arduino-iot-cloud.js

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
/*
22
* Copyright 2019 ARDUINO SA (http://www.arduino.cc/)
3-
* This file is part of node-red-contrib-arduino-cloud.
3+
* This file is part of node-red-contrib-arduino-iot-cloud.
44
* Copyright (c) 2019
55
*
66
* This software is released under:
77
* The GNU General Public License, which covers the main part of
8-
* node-red-contrib-arduino-cloud
8+
* node-red-contrib-arduino-iot-cloud
99
* The terms of this license can be found at:
1010
* https://www.gnu.org/licenses/gpl-3.0.en.html
1111
*
@@ -50,7 +50,7 @@ module.exports = function (RED) {
5050
this.status({});
5151
},config.id);
5252
}else{
53-
this.status({ fill: "red", shape: "ring", text: "arduino-cloud.status.connection-error" });
53+
this.status({ fill: "red", shape: "ring", text: "arduino-iot-cloud.status.connection-error" });
5454
}
5555
this.on('close', function (done) {
5656
connectionManager.deleteClientMqtt(connectionConfig.credentials.clientid, this.thing, this.propertyVariableName,config.id).then(() => { done(); });
@@ -88,7 +88,7 @@ module.exports = function (RED) {
8888
if (typeof msg.payload !== "object") {
8989
s = getStatus(msg.payload);
9090
}else{
91-
s="arduino-cloud.status.object-sent";
91+
s="arduino-iot-cloud.status.object-sent";
9292
}
9393
if (s != undefined)
9494
this.status({ fill: "grey", shape: "dot", text: s });
@@ -106,14 +106,14 @@ module.exports = function (RED) {
106106
console.log(err);
107107
}
108108

109-
this.status({ fill: "red", shape: "dot", text: "arduino-cloud.status.error-setting-value" });
109+
this.status({ fill: "red", shape: "dot", text: "arduino-iot-cloud.status.error-setting-value" });
110110
}
111111
});
112112
this.on('close', function (done) {
113113
connectionManager.deleteClientHttp(connectionConfig.credentials.clientid).then(() => { done(); });
114114
});
115115
}else{
116-
this.status({ fill: "red", shape: "ring", text: "arduino-cloud.status.connection-error" });
116+
this.status({ fill: "red", shape: "ring", text: "arduino-iot-cloud.status.connection-error" });
117117
}
118118
}
119119
} catch (err) {
@@ -181,9 +181,9 @@ module.exports = function (RED) {
181181
}]
182182
}
183183
);
184-
var str = RED._("arduino-cloud.status.sent");
184+
var str = RED._("arduino-iot-cloud.status.sent");
185185
str += data.length;
186-
str += RED._("arduino-cloud.status.elements");
186+
str += RED._("arduino-iot-cloud.status.elements");
187187
this.status({ fill: "grey", shape: "dot", text: str });
188188
}
189189
}catch (err) {
@@ -198,7 +198,7 @@ module.exports = function (RED) {
198198
console.log(err);
199199
}
200200

201-
this.status({ fill: "red", shape: "dot", text: "arduino-cloud.status.error-getting-value" });
201+
this.status({ fill: "red", shape: "dot", text: "arduino-iot-cloud.status.error-getting-value" });
202202
}
203203
});
204204

@@ -207,7 +207,7 @@ module.exports = function (RED) {
207207
});
208208
}
209209
}else{
210-
this.status({ fill: "red", shape: "ring", text: "arduino-cloud.status.connection-error" });
210+
this.status({ fill: "red", shape: "ring", text: "arduino-iot-cloud.status.connection-error" });
211211
}
212212
} catch (err) {
213213
if(err.response && err.response.res && err.response.request){
@@ -221,7 +221,7 @@ module.exports = function (RED) {
221221
console.log(err);
222222
}
223223

224-
this.status({ fill: "red", shape: "dot", text: "arduino-cloud.status.error-getting-value" });
224+
this.status({ fill: "red", shape: "dot", text: "arduino-iot-cloud.status.error-getting-value" });
225225
}
226226
}
227227
}
@@ -257,7 +257,7 @@ module.exports = function (RED) {
257257
}
258258
}
259259
}else{
260-
this.status({ fill: "red", shape: "ring", text: "arduino-cloud.status.connection-error" });
260+
this.status({ fill: "red", shape: "ring", text: "arduino-iot-cloud.status.connection-error" });
261261
}
262262
} catch (err) {
263263
if(err.response && err.response.res && err.response.request){
@@ -306,7 +306,7 @@ module.exports = function (RED) {
306306
}
307307

308308
this.pollTimeoutPoll = setTimeout(() => { this.poll(connectionConfig, pollTime) }, pollTime * 1000);
309-
this.status({ fill: "red", shape: "dot", text: "arduino-cloud.status.error-getting-value" });
309+
this.status({ fill: "red", shape: "dot", text: "arduino-iot-cloud.status.error-getting-value" });
310310
}
311311
}
312312
}
@@ -356,14 +356,14 @@ module.exports = function (RED) {
356356
console.log(err);
357357
}
358358

359-
this.status({ fill: "red", shape: "dot", text: "arduino-cloud.status.error-getting-value" });
359+
this.status({ fill: "red", shape: "dot", text: "arduino-iot-cloud.status.error-getting-value" });
360360
}
361361
});
362362
this.on('close', function (done) {
363363
connectionManager.deleteClientHttp(connectionConfig.credentials.clientid).then(() => { done(); });
364364
});
365365
}else{
366-
this.status({ fill: "red", shape: "ring", text: "arduino-cloud.status.connection-error" });
366+
this.status({ fill: "red", shape: "ring", text: "arduino-iot-cloud.status.connection-error" });
367367
}
368368
}
369369
} catch (err) {
@@ -378,7 +378,7 @@ module.exports = function (RED) {
378378
console.log(err);
379379
}
380380

381-
this.status({ fill: "red", shape: "dot", text: "arduino-cloud.status.error-getting-value" });
381+
this.status({ fill: "red", shape: "dot", text: "arduino-iot-cloud.status.error-getting-value" });
382382
}
383383
}
384384
}
@@ -414,13 +414,13 @@ module.exports = function (RED) {
414414
} else if (req.query.connectionid) {
415415
const connectionConfig = RED.nodes.getNode(req.query.connectionid);
416416
if (!connectionConfig) {
417-
str=RED._("arduino-cloud.connection-error.no-cred-available");
417+
str=RED._("arduino-iot-cloud.connection-error.no-cred-available");
418418
console.log(str);
419419
return res.send(JSON.stringify({ error: str }));
420420
}
421421
arduinoRestClient = await connectionManager.getClientHttp(connectionConfig);
422422
} else {
423-
str=RED._("arduino-cloud.connection-error.no-cred-available");
423+
str=RED._("arduino-iot-cloud.connection-error.no-cred-available");
424424
console.log(str);
425425
return res.send(JSON.stringify({ error: str }));
426426
}
@@ -430,12 +430,12 @@ module.exports = function (RED) {
430430
const thing_id = req.query.thing_id;
431431
return res.send(JSON.stringify(await arduinoRestClient.getProperties(thing_id)));
432432
} else {
433-
str=RED._("arduino-cloud.connection-error.wrong-param");
433+
str=RED._("arduino-iot-cloud.connection-error.wrong-param");
434434
console.log(str);
435435
return res.send(JSON.stringify({ error: str }));
436436
}
437437
} catch (err) {
438-
str=RED._("arduino-cloud.connection-error.wrong-cred-sys-unvail");
438+
str=RED._("arduino-iot-cloud.connection-error.wrong-cred-sys-unvail");
439439
console.log(`Status: ${err.status}, message: ${err.error}`);
440440
return res.send(JSON.stringify({ error: str }));
441441
}
@@ -456,5 +456,5 @@ function getStatus(value) {
456456
else
457457
return value;
458458
}
459-
return RED._("arduino-cloud.status.object-injected");
459+
return RED._("arduino-iot-cloud.status.object-injected");
460460
}

locales/en-US/arduino-cloud.html renamed to locales/en-US/arduino-iot-cloud.html

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ <h3>Outputs</h3>
4646
<h3>Details</h3>
4747
<h4>Node Properties</h4>
4848
<code>Connection</code>
49-
<p>This property allow to set up a connection to Arduino Cloud.</p>
50-
<p>Get Client ID and Client Secret from Arduino Cloud and create or select a connection.</p>
49+
<p>This property allow to set up a connection to Arduino IoT Cloud.</p>
50+
<p>Get Client ID and Client Secret from Arduino IoT Cloud and create or select a connection.</p>
5151
<code>Thing</code>
5252
<p>Choose an Arduino Thing.</p>
5353
<code>Property</code>
@@ -92,8 +92,8 @@ <h3>Inputs</h3>
9292
<h3>Details</h3>
9393
<h4>Node Properties</h4>
9494
<code>Connection</code>
95-
<p>This property allow to set up a connection to Arduino Cloud.</p>
96-
<p>Get Client ID and Client Secret from Arduino Cloud and create or select a connection.</p>
95+
<p>This property allow to set up a connection to Arduino IoT Cloud.</p>
96+
<p>Get Client ID and Client Secret from Arduino IoT Cloud and create or select a connection.</p>
9797
<code>Thing</code>
9898
<p>Choose an Arduino Thing.</p>
9999
<code>Property</code>
@@ -103,7 +103,7 @@ <h4>Node Properties</h4>
103103
</script>
104104

105105
<script type="text/x-red" data-help-name="property in hist">
106-
<p>This node injects in the flow a set of values of an Arduino Cloud Property based on the node configuration.</p>
106+
<p>This node injects in the flow a set of values of an Arduino IoT Cloud Property based on the node configuration.</p>
107107
<h3>Inputs</h3>
108108
<dl class="message-properties">
109109
Any input message triggers a request to get the set of values.
@@ -146,8 +146,8 @@ <h3>Outputs</h3>
146146
<h3>Details</h3>
147147
<h4>Node Properties</h4>
148148
<code>Connection</code>
149-
<p>This property allow to set up a connection to Arduino Cloud.</p>
150-
<p>Get Client ID and Client Secret from Arduino Cloud and create or select a connection.</p>
149+
<p>This property allow to set up a connection to Arduino IoT Cloud.</p>
150+
<p>Get Client ID and Client Secret from Arduino IoT Cloud and create or select a connection.</p>
151151
<code>Thing</code>
152152
<p>Choose an Arduino Thing.</p>
153153
<code>Property</code>
@@ -160,7 +160,7 @@ <h4>Node Properties</h4>
160160
</script>
161161

162162
<script type="text/x-red" data-help-name="property in poll">
163-
<p>This node injects in the flow the value of an Arduino Cloud Property with a periodicity based on the node configuration.</p>
163+
<p>This node injects in the flow the value of an Arduino IoT Cloud Property with a periodicity based on the node configuration.</p>
164164
<h3>Outputs</h3>
165165

166166
<dl class="message-properties">
@@ -199,8 +199,8 @@ <h3>Outputs</h3>
199199
<h3>Details</h3>
200200
<h4>Node Properties</h4>
201201
<code>Connection</code>
202-
<p>This property allow to set up a connection to Arduino Cloud.</p>
203-
<p>Get Client ID and Client Secret from Arduino Cloud and create or select a connection.</p>
202+
<p>This property allow to set up a connection to Arduino IoT Cloud.</p>
203+
<p>Get Client ID and Client Secret from Arduino IoT Cloud and create or select a connection.</p>
204204
<code>Thing</code>
205205
<p>Choose an Arduino Thing.</p>
206206
<code>Property</code>
@@ -257,8 +257,8 @@ <h3>Outputs</h3>
257257
<h3>Details</h3>
258258
<h4>Node Properties</h4>
259259
<code>Connection</code>
260-
<p>This property allow to set up a connection to Arduino Cloud.</p>
261-
<p>Get Client ID and Client Secret from Arduino Cloud and create or select a connection.</p>
260+
<p>This property allow to set up a connection to Arduino IoT Cloud.</p>
261+
<p>Get Client ID and Client Secret from Arduino IoT Cloud and create or select a connection.</p>
262262
<code>Thing</code>
263263
<p>Choose an Arduino Thing.</p>
264264
<code>Property</code>

locales/en-US/arduino-cloud.json renamed to locales/en-US/arduino-iot-cloud.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"arduino-cloud":{
2+
"arduino-iot-cloud":{
33
"config":{
44
"node":{
55
"connection":"Connection",

package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"name": "node-red-contrib-arduino-cloud",
2+
"name": "node-red-contrib-arduino-iot-cloud",
33
"version": "0.9.0",
44
"description": "Node-RED nodes to talk to Arduino IoT Cloud",
55
"scripts": {
@@ -14,7 +14,7 @@
1414
"license": "MIT",
1515
"node-red": {
1616
"nodes": {
17-
"Property": "arduino-cloud.js"
17+
"Property": "arduino-iot-cloud.js"
1818
}
1919
},
2020
"dependencies": {

readme.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
# node-red-contrib-arduino-cloud
1+
# node-red-contrib-arduino-iot-cloud
22

33
This module implements node-red nodes for interacting with [Arduino IoT Cloud](https://create.arduino.cc/iot).
44
Multi Arduino Accounts are allowed.
55

66
## Installation
7-
Install node-red-contrib-arduino-cloud with:
7+
Install node-red-contrib-arduino-iot-cloud with:
88

99
`npm install -g https://github.com/arduino/node-red-contrib-arduino-iot-cloud.git`
1010

@@ -33,14 +33,14 @@ This node injects in the flow the changed value of a specific Arduino IoT Cloud
3333
This node update a specific Arduino IoT Cloud property with the value received in input
3434

3535
### historic
36-
This node injects in the flow a set of values of an Arduino Cloud Property based on the node configuration.
36+
This node injects in the flow a set of values of an Arduino IoT Cloud Property based on the node configuration.
3737
Node parameter:
3838
+ Time Filter: defines time range for historical values
3939

4040
### periodic
41-
This node injects in the flow the value of an Arduino Cloud Property with a periodicity based on the node configuration.
41+
This node injects in the flow the value of an Arduino IoT Cloud Property with a periodicity based on the node configuration.
4242
Node parameter:
4343
+ Poll Every: defines polling time interval (seconds, minutes, hours, days, weeks)
4444

4545
### inject
46-
This node injects in the flow the value of an Arduino Cloud Property after receiving an input event.
46+
This node injects in the flow the value of an Arduino IoT Cloud Property after receiving an input event.

0 commit comments

Comments
 (0)