V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX 提问指南
swx934
V2EX  ›  问与答

在 ubuntu 上安装 python3 模块老是提示‘......you may want sudo's -H flag.....’不知道是否成功安装,以及后续如何调整避免这样的提示

  •  
  •   swx934 · 2017-12-07 15:58:06 +08:00 · 5846 次点击
    这是一个创建于 2346 天前的主题,其中的信息可能已经有所发展或是发生改变。

    在 ubuntu 上安装 python3 模块老是提示‘......you may want sudo's -H flag.....’不知道是否成功安装?以及后续如何调整?避免这样的提示

    wilson@linux:~$ sudo pip3 install send2trash The directory '/home/wilson/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag. The directory '/home/wilson/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.

    7 条回复    2017-12-07 22:37:13 +08:00
    zgx030030
        1
    zgx030030  
       2017-12-07 16:13:44 +08:00
    提示让你用 sudo 来执行啊老哥。。。
    swx934
        2
    swx934  
    OP
       2017-12-07 16:15:59 +08:00
    我加了的啊
    zgx030030
        3
    zgx030030  
       2017-12-07 16:23:16 +08:00
    @swx934 哦那我看错了哈哈, 你加-H 试试? sudo -H pip install xxx
    swx934
        4
    swx934  
    OP
       2017-12-07 16:32:00 +08:00
    问已经解决了,安装 pip3 需要授权管理权限,待 pip3 安装完成后,通过其安装第三方模块旧不需要授权管理权限,直接安装旧可以了。
    Trim21
        5
    Trim21  
       2017-12-07 21:27:11 +08:00
    @swx934 #4 是先用 sudo -H 安装 pip3 吗?
    swx934
        6
    swx934  
    OP
       2017-12-07 22:10:30 +08:00
    不要加-H,直接 sudo
    rob001
        7
    rob001  
       2017-12-07 22:37:12 +08:00
    权限不足
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   2968 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 26ms · UTC 15:02 · PVG 23:02 · LAX 08:02 · JFK 11:02
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.