How can I get the slc command to work on Ubuntu?
Asked Answered
D

5

6

I have installed Strongloop using npm install -g strongloop on my Ubuntu 14.04 server. The slc command does not work. It says

The program 'slc' is currently not installed. You can install it by typing: sudo apt-get install heimdal-multidev

How can I get it to run the Strongloop CLI instead of looking for this package? I have added this to my PATH and it still doesn't work. Any ideas?

Other Strongloop commands, like sl-build work and strongloop is listed in npm list -g.

Drew answered 24/3, 2015 at 0:31 Comment(0)
D
1

Looks like the Node installation that optionally comes with a Digital Ocean Droplet installs to a different location that's not in $PATH. I'm pretty sure that was the issue. Anyways, I fixed it by spinning up a server without Node pre-installed and followed this guide. Just use npm install -g strongloop instead of strong-cli because the latter has been deprecated.

Drew answered 24/3, 2015 at 3:11 Comment(0)
S
7

Ubuntu 14 with node.js 4.1.2

By default somehow slc is not created or not added to PATH. I solved this problem by adding symlink:

sudo ln -s /usr/lib/node_modules/strongloop/bin/slc.js /usr/bin/slc
Sisile answered 27/10, 2015 at 8:50 Comment(0)
S
4

A soft link named slc should have been created at /usr/local/bin which will point to strongloop binary.

Please verify if the following exists.

/usr/local/lib/node_modules/strongloop/bin/slc

If no, then strongloop did not get installed successfully, otherwise verify the existence of the softlink slc at /usr/local/bin/.

/usr/local/bin/slc -> /usr/local/lib/node_modules/strongloop/bin/slc

If yes, then /usr/local/bin needs to be added to the $PATH, otherwise create the softlink and verify that /usr/local/binin $PATH.

Strap answered 24/3, 2015 at 3:7 Comment(1)
I actually just fixed the issue. I'll post another answer. Don't delete yours. It may help people in the future.Drew
D
1

Looks like the Node installation that optionally comes with a Digital Ocean Droplet installs to a different location that's not in $PATH. I'm pretty sure that was the issue. Anyways, I fixed it by spinning up a server without Node pre-installed and followed this guide. Just use npm install -g strongloop instead of strong-cli because the latter has been deprecated.

Drew answered 24/3, 2015 at 3:11 Comment(0)
L
0

Ubuntu 14.04 with node.js 4.4.2 (LTS) :

The installation of strongloop was done without any errors but slc was not added to the PATH. I solved this problem by adding the symlink:

    sudo ln -s /usr/local/lib/node_modules/strongloop/bin/slc.js /usr/bin/slc
Lexie answered 5/4, 2016 at 21:2 Comment(0)
P
0

Actually i am not sure my case matches with yours but i want to share my experience. i got the same message anyway.

I realized that i had changed prefix of global packets before. Then i checked prefix with the following command.

$ npm config get prefix /home/myUser/.node_modules_global

Then i added the path to PATH variable (but .profile, .bash_profile files will be better) in active command line window and problem solved.

Plemmons answered 4/11, 2016 at 7:5 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.