Keystone: Command 'yo' does not exist
I’m trying to install Keystone.js which as a pre-requisite, requires installation of both Node and MongoDB, so I followed the following posts to do so:
This has installed a ‘stable’ version of NodeJS on my server. However, when I then install keystone with the following commands:
npm install -g generator-keystone
and create a directory:
mkdir test-directory cd test-directory
I’m required to run the generator
yo: command not found
Searching around, it’s cleary that perhaps my PATH wasn’t exported:
but that doesn’t fix the issue. So I decided to follow the advice of the last post here instead, which uninstalls grunt and yo, and reinstalls yo:
But after uninstalling both packages, I’m now faced with this error upon reinstalling just yo:
sh: 1: node: not found npm WARN This failure might be due to the use of legacy binary "node" npm WARN For further explanations, please read /usr/share/doc/nodejs/README.Debian
How do I resolve this?
For reference, the Keystone documentation is here for installation - http://keystonejs.com/getting-started/
It is probably related to a shift in commands from one version of node to the other, so perhaps I should be installing a specific version of node instead?
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.×