Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running "ionic" CLI gives "Cannot find module 'colors'" #574

Closed
mhartington opened this issue Aug 27, 2015 · 4 comments
Closed

Running "ionic" CLI gives "Cannot find module 'colors'" #574

mhartington opened this issue Aug 27, 2015 · 4 comments

Comments

@mhartington
Copy link
Member

From @cyraid on August 27, 2015 10:31

I've installed Ionic 1.6.4 through NPM, and it seems when I want to run it, it gives the error "Cannot find module 'colors'". Just installed it today. I'm using Node.JS 0.12.7, and NPM 2.11.3

O.S. Is Ubuntu 15.04, 64bit

Copied from original issue: ionic-team/ionic-framework#4282

@cyraid
Copy link

cyraid commented Aug 27, 2015

You gave me a link that changed the original report.. Should I replace the iid in the URL and copy the info from the old one to update this one?

@mhartington
Copy link
Member Author

You should go all set, the necessary info is there.

@cyraid
Copy link

cyraid commented Aug 31, 2015

Any information on this bug? It's a blocker, and I can't even use it.. I've created a project with it, and I need to get this 'proof of concept' app done ASAP.

@cyraid
Copy link

cyraid commented Sep 1, 2015

EDIT: Nevermind, it used two different installation directories.. The old NodeJS from Universe uses /usr/local/lib/node_modules and the new one uses /usr/lib/node_modules .. And it was using the old ionic and working.. The new one at /usr/lib/node_modules gives that error.. Perhaps it's NodeJS and it's new location that's causing it.

I managed to fix this by removing NPM/NodeJS, then reinstalling NPM from Ubuntu Universe, then using the:
curl --silent --location https://deb.nodesource.com/setup_0.12 | sudo bash -
Then:
sudo apt-get install nodejs
(To upgrade NodeJS and get the Node 0.12.x recommended by Ionic CLI), then installed (using sudo):
sudo npm install -g cordova
sudo npm install -g ionic
And it seemed to work.. Not sure why having NodeJS from universe first was needed.. Regardless, you can close this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants