js-beautify
js-beautify copied to clipboard
Broken CI workflow due to incompatible NPM and Node versions
Description
The Github action workflows are broken due to incompatible new version of NPM being run against Node. The offending code is below, it can easily be fixed if I can find out the original reason for its existence. https://github.com/beautify-web/js-beautify/blob/12bc378bd465dc8771609c4a181d49462dbf7dd1/tools/npm#L7-L11
Error:
ERROR: npm v9.1.2 is known not to run on Node.js v12.22.12. You'll need to
upgrade to a newer Node.js version in order to use this version of npm. This
version of npm supports the following node versions: `^14.17.0 || ^16.13.0 ||
>=18.0.0`. You can find the latest version at [https://nodejs.org/.](https://nodejs.org/)
On a related note, @bitwiseman I was wondering why does this package have node
, npm
and python*
scripts in the tools
directory. Those scripts make it hard to use any of the language engines on individual machines. A better alternative would be to have Docker files to run commands instead of updating packages on every computer that runs the tests or build code.
@mhnaeem I fixed the GHA workflows. These scripts were started before I docker was a thing. Or at least before I understood how to use it. PRs welcome to convert to a docker based system.