LinuxWARNING: The script locust is installed in ‘/home/xxx/bin‘ which is not on PATH.
Posted Xavier Jiezou
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了LinuxWARNING: The script locust is installed in ‘/home/xxx/bin‘ which is not on PATH.相关的知识,希望对你有一定的参考价值。
问题描述
使用命令 pip install locust
安装后弹出如下警告:
Installing collected packages: locust
WARNING: The script locust is installed in '/home/xuechao/.local/bin' which is not on PATH.
Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed locust-2.2.1
原因分析
'/home/xuechao/.local/bin'
未添加到环境变量。
解决方案
echo 'export PATH=/home/xxx/bin:$PATH' >>~/.bashrc
source ~/.bashrc
注意事项
将 xxx
替换为你的用户名和路径,比如我这里应该替换为 xuecaho/.local
以上是关于LinuxWARNING: The script locust is installed in ‘/home/xxx/bin‘ which is not on PATH.的主要内容,如果未能解决你的问题,请参考以下文章