Location or method to query 'somewhere' for latest version # of NR?

Want to setup a flow that checks the installed version of NR against 'somewhere' the version available. Check for updates type of thing? I guess I could page grab nodered.org? Or even better npm search?

# npm search node-red | grep Low-code | cut -d '|' -f5

More elegant way or official way to do this?

I am using an exec node and the npm outdated command to check my Node-RED install and multiple workspaces for updates.

Try the following from an exec node: cd /path/to/node-red/ && npm outdated --json

Please note that you need a proper package.json at the locations in question, and requires Node-RED to be installed locally in a separate directory.

The following command will get you the version number of the current latest release of Node-RED.

npm info node-red dist-tags.latest
1 Like

Cool, I also figured out the following...

npm search node-red | grep Low-code | cut -d '|' -f4-5

Now I am trying to figure out how to get information on installed NR version? Is there a easy way to get that? I can get NPM installed version and node installed version, but NR installed version is proving a bit tricky.

Looking at the tags, shows next as well, nice.

So NPM can't report the installed version of NR, only the available version of NR? I tried...

# npm list | grep node-red

in the ~/.node-red directory. And a few other variants and only results are the available version of node-red, not installed version. In fact I only find the installed/active version reported in the node-red-log?

The above command shows all the components related to node-red, but not node-red its self?

usually Node-RED is installed globally - so maybe try adding -g

npm ls -g --depth=0 | grep node-red | cut  -d '@' -f 2

Oh so the standard script installs global? Ok, that makes sense now that you mention it, I was thinking it was local, especially when I install under a non-root id. And I did get the installed version...

โ”œโ”€โ”ฌ node-red@1.1.1
โ”‚ โ”œโ”€โ”ฌ @node-red/editor-api@1.1.1
โ”‚ โ”‚ โ”œโ”€โ”€ @node-red/editor-client@1.1.1
โ”‚ โ”‚ โ”œโ”€โ”€ @node-red/util@1.1.1 deduped
โ”‚ โ”œโ”€โ”ฌ @node-red/nodes@1.1.1
โ”‚ โ”œโ”€โ”ฌ @node-red/runtime@1.1.1
โ”‚ โ”‚ โ”œโ”€โ”ฌ @node-red/registry@1.1.1
โ”‚ โ”‚ โ”‚ โ”œโ”€โ”€ @node-red/util@1.1.1 deduped
โ”‚ โ”‚ โ”œโ”€โ”€ @node-red/util@1.1.1 deduped
โ”‚ โ”œโ”€โ”ฌ @node-red/util@1.1.1
โ”‚ โ”œโ”€โ”ฌ node-red-admin@0.2.6
โ”‚ โ”œโ”€โ”€ node-red-node-rbe@0.2.9
โ”‚ โ”œโ”€โ”ฌ node-red-node-tail@0.1.1

This is cool, so now I can finish my flow that does a check on available version versus installed version. @dceejay Thanks! And @knolleary, for the tags reference too.

of course npm -g outdated would also show if it were not at latest.

Nice. :slight_smile: Thanks.

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