Search code examples
node.jswebatom-editornuclide-editor

Nuclide + Atom remote development des not work on Ubuntu 16.04


I trying to start Nuclide + Atom with remote development.

I've installed Nuclide via Package manager on Atom and install Nuclide Server (Ubuntu 16.04)

npm install -g nuclide

My first trouble was:

nohup: failed to run command 'node': No such file or directory

in nuclide-server-start log file, but i solve it by nodejs vs node on ubuntu 12.04 (don't think this right... :) but it works for me)

And i got a second trouble:

/usr/local/lib/node_modules/nuclide/pkg/nuclide-server/lib/nuclide-main.js:20
const {__DEV__} = require('../../nuclide-node-transpiler/lib/env');
      ^

    SyntaxError: Unexpected token {
        at exports.runInThisContext (vm.js:53:16)
        at Module._compile (module.js:374:25)
        at Object.Module._extensions..js (module.js:417:10)
        at Module.load (module.js:344:32)
        at Function.Module._load (module.js:301:12)
        at Function.Module.runMain (module.js:442:10)
        at startup (node.js:136:18)
        at node.js:966:3

in nuclide-server-start log file.

when i installing nuclide-server by npm it tells me

WARN engine [email protected]: wanted: {"atom":">=1.14.1","node":">=6.5.0"} (current: {"node":"4.2.6","npm":"3.5.2"})

may is that a reason of my troubles?

Somebody help! :)


Solution

  • First i tried to update my nodeJS from npm:

    $ sudo npm install -g node
    

    and i got an answer:

    npm WARN deprecated [email protected]: To update or install node, go to http://nodejs.org/
    /usr/local/lib
    └── [email protected] 
    

    then i try some way to update my nodeJs, described here: https://github.com/kevincobain2000/instagram-bot-api/issues/1

        $ sudo npm cache clean -f && sudo npm install -g n && sudo n stable
    
    npm WARN using --force I sure hope you know what you are doing.
    /usr/local/bin/n -> /usr/local/lib/node_modules/n/bin/n
    /usr/local/lib
    └── [email protected] 
    
         install : node-v7.6.0
           mkdir : /usr/local/n/versions/node/7.6.0
           fetch : https://nodejs.org/dist/v7.6.0/node-v7.6.0-linux-x64.tar.gz
    ######################################################################## 100.0%
       installed : v7.6.0
    

    and after that nuclide-server-start was successfully started! :)