Git Product home page Git Product logo

libsass-build-sublime's People

Contributors

blitzrk avatar

Watchers

 avatar

libsass-build-sublime's Issues

Error: Cannot find module 'npm'

On Sublime Text 3 in Windows 7, when I installed this package, It throws the following error
error

Path of node_modules in my system is : -
C:\Program Files\nodejs\node_modules

I set the path like this in libsass.sublime-build file :-

{
"cmd": [
"node",
"$packages/libsass-build-sublime/build.js",
"$file",
"$packages/User/LibSassBuild.sublime-settings"
],
"working_dir": "$file_path",
"selector": "source.scss, source.sass",
"windows": { "path": "C:/Program Files/nodejs/node_modules" },
"osx": { "path": "/usr/local/bin:$PATH" }
}

After this, when I compiled the scss file after restarting Sublime Text 3, I got the below error :-

[WinError 2] The system cannot find the file specified
[cmd: ['node', 'C:\Users\Vaibhav\AppData\Roaming\Sublime Text 3\Packages/libsass-build-sublime/build.js', 'Z:\web2\web\app-web\app\styles_header.scss', 'C:\Users\Vaibhav\AppData\Roaming\Sublime Text 3\Packages/User/LibSassBuild.sublime-settings']]
[dir: Z:\web2\web\app-web\app\styles]
[path: C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\TortoiseHg;C:\Program Files (x86)\Skype\Phone;C:\Ruby22-x64\bin;C:\Program Files\nodejs;C:\Program Files\nodejs\node_modules;C:\Users\Vaibhav\AppData\Roaming\npm]
[Finished]

error2

Can anyone please help in sorting this out ?

Error: Cannot find module 'npm' on mac

Hello,

First, thanks for your plugin. It's the only one like it so far and I hope I'll be able to get it to work.
for now, I keep getting this error when I try to build my scss :

module.js:338
    throw err;
          ^
Error: Cannot find module 'npm'
    at Function.Module._resolveFilename (module.js:336:15)
    at Function.Module._load (module.js:278:25)
    at Module.require (module.js:365:17)
    at require (module.js:384:17)
    at Object.<anonymous> (/Users/myname/Library/Application Support/Sublime Text 3/Packages/libsass-build-sublime/build.js:6:11)
    at Module._compile (module.js:460:26)
    at Object.Module._extensions..js (module.js:478:10)
    at Module.load (module.js:355:32)
    at Function.Module._load (module.js:310:12)
    at Function.Module.runMain (module.js:501:10)
[Finished in 0.1s with exit code 1]
[cmd: ['node', '/Users/myname/Library/Application Support/Sublime Text 3/Packages/libsass-build-sublime/build.js', '/Volumes/Web/myWorkingDirectory/scss/composants/_arbosousmenu.scss', '/Users/myname/Library/Application Support/Sublime Text 3/Packages/User/LibSassBuild.sublime-settings']]
[dir: /Volumes/Web/myWorkingDirectory]
[path: /usr/bin:/bin:/usr/sbin:/sbin]

FYI :

  • I work on macOSX 10.11.2 (El Capitan), with Sublime Text 3
  • My node-sass version is 3.3.3 and libsass 3.2.5
  • when I echo my PATH in a terminal, I get "/Users/myname/npm/bin" and my NODE_PATH points to "/Users/myname/npm/lib/node_modules".

I left the content of libsass.sublime-build as it was originaly, like this :


{
    "cmd": [ 
        "node", 
        "$packages/libsass-build-sublime/build.js", 
        "$file", 
        "$packages/User/LibSassBuild.sublime-settings" 
    ],
    "working_dir": "$file_path",
    "selector": "source.scss, source.sass",
    "osx": { "path": "/usr/local/bin:$PATH" }
}

I tried some things, like changing my PATH and NODE_PATH, updating my node-sass and npm versions, but nothing did it...
Initiating node-sass via command line work fine on my computer, but no way to get it to work with your plugin in ST3. I would really like it, though. And as I'm quite a noob with all this npm stuff, it's pretty hard for me to isolate the problem by myself.

Feel free to ask me for more infos, if needed.
Thanks in advance for your time.

npm outdated is slow

It is singlehandedly slowing down the entire compilation time, yet its only use is to decide whether to output a message about the length of time it takes to compile node-sass.

Could there be another way, such as outputting the message after 1.5s if the compilation isn't started?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.