Merge branch 'dev' into @feature/issue-5029

This commit is contained in:
Debadutta Panda
2025-06-07 10:47:20 +05:30
committed by GitHub
59 changed files with 2075 additions and 574 deletions

View File

@@ -63,7 +63,8 @@ var knownOpts = {
"verbose": Boolean,
"safe": Boolean,
"version": Boolean,
"define": [String, Array]
"define": [String, Array],
"no-telemetry": Boolean
};
var shortHands = {
@@ -98,6 +99,7 @@ if (parsedArgs.help) {
console.log(" --safe enable safe mode");
console.log(" -D, --define X=Y overwrite value in settings file");
console.log(" --version show version information");
console.log(" --no-telemetry do not share usage data with the Node-RED project");
console.log(" -?, --help show this help");
console.log(" admin <command> run an admin command");
console.log("");
@@ -223,6 +225,10 @@ if (process.env.NODE_RED_ENABLE_TOURS) {
settings.editorTheme.tours = !/^false$/i.test(process.env.NODE_RED_ENABLE_TOURS);
}
if (parsedArgs.telemetry === false || process.env.NODE_RED_DISABLE_TELEMETRY) {
settings.telemetry = settings.telemetry || {};
settings.telemetry.enabled = false;
}
var defaultServerSettings = {
"x-powered-by": false

View File

@@ -273,6 +273,7 @@ module.exports = {
* Runtime Settings
* - lang
* - runtimeState
* - telemetry
* - diagnostics
* - logging
* - contextStorage
@@ -311,6 +312,22 @@ module.exports = {
/** show or hide runtime stop/start options in the node-red editor. Must be set to `false` to hide */
ui: false,
},
telemetry: {
/**
* By default, telemetry is disabled until the user provides consent the first
* time they open the editor.
*
* The following property can be uncommented and set to true/false to enable/disable
* telemetry without seeking further consent in the editor.
* The user can override this setting via the user settings dialog within the editor
*/
// enabled: true,
/**
* If telemetry is enabled, the editor will notify the user if a new version of Node-RED
* is available. Set the following property to false to disable this notification.
*/
// updateNotification: true
},
/** Configure the logging output */
logging: {
/** Only console logging is currently supported */
@@ -473,6 +490,7 @@ module.exports = {
* - fileWorkingDirectory
* - functionGlobalContext
* - functionExternalModules
* - globalFunctionTimeout
* - functionTimeout
* - nodeMessageBufferMaxLength
* - ui (for use with Node-RED Dashboard)
@@ -499,7 +517,19 @@ module.exports = {
/** Allow the Function node to load additional npm modules directly */
functionExternalModules: true,
/** Default timeout, in seconds, for the Function node. 0 means no timeout is applied */
/**
* The default timeout (in seconds) for all Function nodes.
* Individual nodes can set their own timeout value within their configuration.
*/
globalFunctionTimeout: 0,
/**
* Default timeout, in seconds, for the Function node. 0 means no timeout is applied
* This value is applied when the node is first added to the workspace - any changes
* must then be made with the individual node configurations.
* To set a global timeout value, use `globalFunctionTimeout`
*/
functionTimeout: 0,
/** The following property can be used to set predefined values in Global Context.