Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

zsh: command not found: jhipster

I couldn't run jhipster generator, got error: zsh: command not found: jhipster

My system is Ubuntu 16.04, I use zsh:

➜ yarn global add generator-jhipster
yarn global v0.24.5
warning No license field
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Installed "[email protected]" with binaries:
      - jhipster
warning No license field
Done in 1.87s.
➜ jhipster
zsh: command not found: jhipster

What did I missed?

Also I have this in my .zshrc:

# npm
export PATH="$PATH:/home/romanovi/.npm-global/bin"
export NODE_PATH="$NODE_PATH:/home/romanovi/.npm-global/lib/node_modules"

# Yarn
export PATH="$PATH:`yarn global bin`"
like image 439
mystdeim Avatar asked May 20 '17 11:05

mystdeim


3 Answers

I had the same problem and solved it by running yarn global bin and adding the returned value to my PATH.

like image 177
Morteza Adi Avatar answered Oct 24 '22 15:10

Morteza Adi


There seems to be an issue with the last update of jhipster to jhipster cli. Can you try yo jhipster instead while #JHipster try to fix the jhipster cli.

like image 44
Edmond Avatar answered Oct 24 '22 15:10

Edmond


This issue seems to be fixed. Reinstall generator-jhipster and it is working again.

yarn global add generator-jhipster
like image 41
Uli Schweikl Avatar answered Oct 24 '22 16:10

Uli Schweikl