zoukankan      html  css  js  c++  java
  • 在ubuntu上安装npm

    sudo apt install npm

    执行上面的安装命令,会报错:

    Reading package lists... Done
    Building dependency tree       
    Reading state information... Done
    Some packages could not be installed. This may mean that you have
    requested an impossible situation or if you are using the unstable
    distribution that some required packages have not yet been created
    or been moved out of Incoming.
    The following information may help to resolve the situation:
    
    The following packages have unmet dependencies:
     npm : Depends: node-gyp (>= 0.10.9) but it is not going to be installed
    E: Unable to correct problems, you have held broken packages.

    执行如下命令能解决上面的问题:

    sudo apt-get install nodejs-dev node-gyp libssl1.0-dev

    再次执行npm安装命令即可。

    完。

  • 相关阅读:
    BZOJ 4525 二分
    BZOJ 4565 状压DP
    BZOJ 3930 容斥原理
    BZOJ 4562 搜索...
    BZOJ 4563 错排+高精度
    BZOJ 1833 数位DP
    BZOJ 4517 组合数+错排
    python 入门学习(二)
    python 入门学习
    Python 爬虫
  • 原文地址:https://www.cnblogs.com/liyou-blog/p/10736527.html
Copyright © 2011-2022 走看看