Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/475.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 终端输出:manpath:can';t设置区域设置;确保$LC_*和$LANG是正确的_Javascript_Node.js_Debugging_Npm_Terminal - Fatal编程技术网

Javascript 终端输出:manpath:can';t设置区域设置;确保$LC_*和$LANG是正确的

Javascript 终端输出:manpath:can';t设置区域设置;确保$LC_*和$LANG是正确的,javascript,node.js,debugging,npm,terminal,Javascript,Node.js,Debugging,Npm,Terminal,在尝试运行特定bash脚本时,我得到以下输出: manpath: can't set the locale; make sure $LC_* and $LANG are correct Running node v4.8.5 (npm v2.15.11) manpath: can't set the locale; make sure $LC_* and $LANG are correct 脚本的内容如下所示: #!/bin/bash . ~/.nvm/nvm.sh cd /home/de

在尝试运行特定bash脚本时,我得到以下输出:

manpath: can't set the locale; make sure $LC_* and $LANG are correct
Running node v4.8.5 (npm v2.15.11)
manpath: can't set the locale; make sure $LC_* and $LANG are correct
脚本的内容如下所示:

 #!/bin/bash

. ~/.nvm/nvm.sh
cd /home/desktop/folder/subfolder && nvm exec 4.8.5 node app.js
如果我使用echo之类的工具编写一个小bash脚本,则不会发生错误。 我以前从未见过这个错误。原因是什么?
其他答案使它看起来像是一个编码错误。我正在使用US.UTF-8。

这对我今天起了作用

echo "LC_ALL=en_US.UTF-8" >> /etc/environment
echo "en_US.UTF-8 UTF-8" >> /etc/locale.gen
echo "LANG=en_US.UTF-8" > /etc/locale.conf
locale-gen en_US.UTF-8
来源于