Foros de discusión
No globally installed themelet found.
Alessandro Candini, modificado hace 7 años.
No globally installed themelet found.
Regular Member Mensajes: 130 Fecha de incorporación: 17/10/15 Mensajes recientes
I've followed this guide to create a themelet.
Everything seems fine, including the npm link command:
But I get a problem trying to install it into my theme:
Why my themelet is not found? Is there a problem with nvm maybe?
Everything seems fine, including the npm link command:
user@host:/home/test/liferayworkspace/themelets/test-themelet$ ll ~/.nvm/versions/node/v6.2.1/lib/node_modules/
totale 24K
lrwxrwxrwx 1 user users 87 giu 8 15:33 test-themelet -> /home/test/liferayworkspace/themelets/test-themelet/
But I get a problem trying to install it into my theme:
user@host:$ gulp extend
[15:28:02] Using gulpfile /home/test/liferayworkspace/themes/test-theme/gulpfile.js
[15:28:02] Starting 'extend'...
? What kind of theme asset would you like to extend? Themelet
? Where would you like to search for themelets? Search globally installed npm modules (development purposes only)
[15:28:04] No globally installed themelet found. Install some with "npm i -g [name]"
Why my themelet is not found? Is there a problem with nvm maybe?
Byrån Zaugg, modificado hace 7 años.
RE: No globally installed themelet found.
Expert Mensajes: 252 Fecha de incorporación: 6/04/12 Mensajes recientes
Could I have you run two commands, to help troubleshoot your setup?
$ node -e "console.log(process.env.NODE_PATH)"
$ npm root -g
Alessandro Candini, modificado hace 7 años.
RE: No globally installed themelet found.
Regular Member Mensajes: 130 Fecha de incorporación: 17/10/15 Mensajes recientes
Sure:
Maybe that undefined should be fixed in some way?
user@host:$ node -e "console.log(process.env.NODE_PATH)"
undefined
user@host:$ npm root -g
/home/user/.nvm/versions/node/v6.2.1/lib/node_modules
Maybe that undefined should be fixed in some way?
Nate Cavanaugh, modificado hace 7 años.
RE: No globally installed themelet found.
Junior Member Mensajes: 94 Fecha de incorporación: 27/11/06 Mensajes recientes
Hi Alessando,
I've gone ahead and commented on the Github issue.
Let us know if you need anything else!
I've gone ahead and commented on the Github issue.
Let us know if you need anything else!
Alessandro Candini, modificado hace 7 años.
RE: No globally installed themelet found. (Respuesta)
Regular Member Mensajes: 130 Fecha de incorporación: 17/10/15 Mensajes recientes
Thank you Nate, as you suggested on github I solved adding to my ~/.bashrc file the following line:
After that I got:
Thank you!
export NODE_PATH="$NODE_PATH:$HOME/.nvm/versions/node/v6.2.1/lib/node_modules/"
After that I got:
user@host:$ node -e "console.log(process.env.NODE_PATH)"
:/home/user/.nvm/versions/node/v6.2.1/lib/node_modules/
and I was able to install my themelet.Thank you!