nodejs let notifier = require('update-notifier')({pkg}) 报错

先卸载nodejs,然后安装稳定最新版

# apt-get remove nodejs   //删除nodejs
# curl -sL https://deb.nodesource.com/setup_8.x | sudo bash - //nodejs源
# apt-get update //更新包
# apt-get install nodejs //安装nodejs
# npm install npm -g //更新npm

Cannot find module 'are-we-there-yet'

1) Go to the global node_modules directory (what would npm root -g print if you could run it):

$ cd /usr/local/lib/node_modules
2) Remove the broken npm directory or move it somewhere else (note that you might need to elevate permissions for this and the following steps): $ mv npm /tmp
3) Download and unpack fresh npm from the registry (substitute version you want to install, e.g. 3.10.8): $ curl -L registry.npmjs.com/npm/-/npm-{VERSION}.tgz | tar xz --transform="s:^package:npm:"
You can automate some of that with this install script: $ curl -L https://www.npmjs.com/install.sh | sh

参考

ubuntu 安装 npm、nodejs 各种问题的更多相关文章

  1. Ubuntu安装新版本nodejs的5种姿势

    引言: 写这篇文章之前,关于ubuntu14.04(Trusty)默认安装的NodeJS版本是0.10.25百思不解(什么鬼,哪一年的NodeJS) 写这篇文章之时,NodeJS的LTS版本号都已经1 ...

  2. ubuntu 安装nodejs/npm

    安装发行稳定版 Ubuntu 默认仓库里带有Node.js,版本较旧,这并不是最新版,但是应该很稳定.执行如下命令:   1 2 sudo apt-getupdate sudo apt-getinst ...

  3. ubuntu 安装Nodejs

    ubuntu 安装Nodejs 1.在软件管理器里面安装nodejs2.由于版本很老,所以需要更新版本:先安装npm , sudo apt install npm然后用npm安装 n 命令,更新nod ...

  4. Ubuntu安装Node和npm

    本文简单介绍在Ubuntu上安装最新版本的node和npm. 本次试验环境是Ubuntu 18.10. 安装nodejs root@ubuntu:~# cat /etc/issue Ubuntu 18 ...

  5. ubuntu 安装 nodejs

    http://blog.csdn.net/caib1109/article/details/51804687 我的系统环境: Ubuntu 16.04 64位 本文内容亲测可用, 请放心食用 使用淘宝 ...

  6. 安装了nodejs后在命令行运行npm报错

    安装了nodejs后在命令行运行npm报错:Error: Cannot find module 'internal/util/types' 解决方法:删除目录“C:\Users\mengxiaobo\ ...

  7. 安装nodejs安装npm安装cpnm安装vue-cli脚手架

    1.为什么用nodejs 因为它是javascript运行环境,不同系统直接运行各种编程语言 是我即将使用vue的推荐开发环境. 选择对应版本,https://nodejs.org/en/downlo ...

  8. ubuntu安装最新版node和npm

    1.先在系统上安装好nodejs和npm           sudo apt-get install nodejs-legacy sudo apt-get install npm     2.升级n ...

  9. nodeJs 安装 npm nodeModules package.json

    Nodejs   1.安装nodejs 从nodejs官网下载最新版本的node,设置环境变量这样就可以在cmd下直接用命令行操作npm 环境变量:path  d:/nodejs 查看本机node及n ...

随机推荐

  1. Head First Servlet and JSP

    这书是原本这样还是翻译的问题?好多的地方大小写都写错了,比如javax.servlet,<servlet></servlet>.真是坑啊.

  2. 选择排序SelectionSort

    转自https://www.cnblogs.com/shen-hua/p/5424059.html a) 原理:每一趟从待排序的记录中选出最小的元素,顺序放在已排好序的序列最后,直到全部记录排序完毕. ...

  3. c# 如何读取web.config中的内容(ConfigurationManager)

    1.web.config中写入 <appSettings>    <add key="TokenQPark" value="http://localho ...

  4. status.go

    )))     return key }

  5. 安卓---RedioButton(单选按钮)、CheckBox(复选按钮)

    <RadioGroup android:layout_width="fill_parent" android:layout_height="wrap_content ...

  6. java equals和tostring

    Object类概述 是所有类中的父类,最大的超类,所有的类都继承他. equals方法 比较2个对象是否相同,其实他是在比较两个对象的地址是否相同,在equals方法中我们用==来判断 但是比较2个地 ...

  7. HrbustOJ 1564 螺旋矩阵

    Description 对于给定的一个数n,要你打印n*n的螺旋矩阵. 比如n=3时,输出: 1 2 3 8 9 4 7 6 5 Input 多组测试数据,每个测试数据包含一个整数n(1<=n& ...

  8. Java连接redis

    一.依赖包 jedis-2.1.0.jar   commons-pool-1.6.jar 二.实例 //连接参数public class RedisConfig { public static int ...

  9. C# 通俗说 委托(和事件)

    1.闲聊 编码一两年, 我走过了字段, 我跑过了类, 却翻不过方法.(不能灵活使用方法吧) (写这篇博客全程听将夜中<永夜>歌曲写完的,一气呵成,安利一下) 2.叙事 我们在编码中,经常捣 ...

  10. JPA中自定义的插入、更新、删除方法为什么要添加@Modifying注解和@Transactional注解?

    前几天,有个同事在使用JPA的自定义SQL方法时,程序一直报异常,捣鼓了半天也没能解决,咨询我的时候,我看了一眼他的程序,差不多是这个样子的: @Repository public interface ...