bash: express: command not found... #324
-
I have followed up with http://expressjs.com/en/starter/generator.html for express application generator, got this issue bash: express: command not found.... Tried on both windows 2016 and RHEL 8 , I got same issue. but fixed windows 2016 issue by add NODE_PATH in environment variable as NODE_PATH=C:\Users\Administrator\AppData\Roaming\npm\node_modules. but no luck on RHEL 8 by using echo 'export NODE_PATH="'$(npm root -g)'"' >> ~/.bash_profile && . ~/.bash_profile to add PATH in bash_profile. Thanks in advance |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments
-
Hi @richardlrzjw, Can you confirm that you first ran the command |
Beta Was this translation helpful? Give feedback.
-
@richardlrzjw please run the npm install -g express-generator command. The express command cannot be found without running the above command |
Beta Was this translation helpful? Give feedback.
-
Thanks oviecodes and e-l-i-s-e, yes, that works for me now. |
Beta Was this translation helpful? Give feedback.
Hi @richardlrzjw, Can you confirm that you first ran the command
npm install -g express-generator
?