Local gulp not found (Try running: npm install gulp)

前端 未结 5 1931
野趣味
野趣味 2021-01-31 13:12

I created a module (webapp-module-storage) which has the following definitions:

package.json

{
  \"dependencies\": {
    ..         


        
相关标签:
5条回答
  • 2021-01-31 13:35

    Try running npm link gulp in your application directory (to create a local link to the globally installed Gulp module).

    0 讨论(0)
  • 2021-01-31 13:36

    Try installing your dependencies first:

    npm install
    

    If still does not work, install gulp globally:

    npm install -g gulp
    

    if you find problems installing it. type sudo before npm.

    In case you need more info about why you need gulp globally and locally read this answer

    0 讨论(0)
  • 2021-01-31 13:43

    npm link gulp --no-bin-links
    Run this

    where npm link gulp creates a local link to globally installed gulp module and --no-bin-links argument will prevent npm from creating symlinks for any binaries the package might contain.

    You can't translate symlinks to a synchronized folder on Windows share, so you will need '--no-bin-links' to go around it.

    Use it for any filesystem that doesn’t support symbolic links.

    Symlinks, or symbolic links, are “virtual” files or folders which reference a physical file or folder located elsewhere, and are an important feature built in to many operating systems, including Linux and Windows.

    0 讨论(0)
  • 2021-01-31 13:51

    npm link gulp --force

    Using this command worked well for me.

    0 讨论(0)
  • 2021-01-31 13:59

    I have tried all the solutions mentioned. At the end I was able to solve the problem by realising that the gulpfile.js file was missing on the location i was using the gulp. After placing the gulpfile.js in the folder from where I was executing gulp, it worked for me.

    0 讨论(0)
提交回复
热议问题