Change Flows file name in existing system

Continuing the discussion from All my nodes and flows gone:

So settings.js only effects a new workspace?

Is it possible to change the name for an existing workspace?
If so, how?

So settings.js only effects a new workspace?

The flow file value in settings.js tells Node-RED what file to load the flows from. So I'm not sure what you mean here by 'only effects a new workspace'.

If you want Node-RED to use a different flow file, then change the value in settings.js and restart.

If you want to rename your existing flows file, then rename it as you would any other file, change the value in settings.js so Node-RED knows about the new name and restart.

Just quoting what @kuema said in the old thread:

(my emphasis)

So I dunno - am I misunderstanding that? Is that wrong?

Ah right. That comment was in the context of a discussion around changing our old default behaviour of generating the flow file name based on hostname, versus having it hardcoded by default in the settings.js file you get when you first run Node-RED.

Since that discussion, we did change the default settings.js file to have flowFile. Anyone who was already running Node-RED with an existing settings.js file would continue to use whatever flow file they had. But any new install of node-red would get the new settings.js file with flowFile set.

If you do not have flowFile in your settings file, then you can just add it and set the value to whatever you want it to be. Just make sure you rename the file to match so Node-RED finds it properly under the new name.

1 Like

Thanks - that clears it up.

I should have said "only affects workspace" :confounded: :man_facepalming:

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.