Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Install Yeoman on C9.io

Has anyone tried to install Yeoman in the Cloud9 environment? If so how to do it?

I get this error on any yeoman command:

<FATAL> EACCES, permission denied '/var/lib/stickshift/' </FATAL>
like image 398
Mandar Limaye Avatar asked Jan 06 '13 13:01

Mandar Limaye


2 Answers

Ok, so I played a little bit with Cloud9 and yeoman ;)

Seems like your error comes mainly from the fact that yeoman is trying to goes up the tree, looking for a Gruntfile.js ... Doing so it encounters an issue as the directory it tries to read are not accessible for the current user.

The first work-around is to create an empty Gruntfile.js:

'use strict';
 module.exports = function (grunt) {
 // Project configuration.
 grunt.initConfig({});
 };

Then launching "yeoman init" will ask you the standard questions and at a given point will ask you if it can overwrite the Gruntfile, which you can answer positively ;)

Then if you launch a "yeoman server", you'll encounter another error, due to the port the server is willing to answer.

Add the following options to your Gruntfile.js:

  server: {
    port: process.env.PORT,
    host: process.env.IP
},

Note that you also need to have Compass installed (gem install compass).

Then launching "yeoman server' will launch the server and the needed task (ending with the watch task) ...

I didn't went further down the path though ;)

Hope this helps. cloud 9 yeoman screenshot

like image 54
sleeper Avatar answered Nov 08 '22 14:11

sleeper


I can install yeoman but after running install for generators, they don't work: $ yo angular Error angular

You don't seem to have a generator with the name angular installed. You can see available generators with npm search yeoman-generator and then install them with npm install [name]. To see the 0 registered generators run yo with the --help option.

Tried a couple other generators, none work so not just an issue with angular.

Then found: Why are my Yeoman generators installing in the wrong place?

Fixed it!

like image 2
raf Avatar answered Nov 08 '22 15:11

raf