这是我第一次尝试安装 Django,当我运行它时,它成功安装了 Django-1.7.3,但我收到了下面的这些警告。我无法在网上找到任何有关它的信息,所以我希望有人能够澄清它们的含义,如果我需要修复它们,以及我该如何去做?
谢谢!下面是我的终端的输出
macbook:~ Asif$ sudo pip install Django
Password:
The directory '/Users/Asif/Library/Logs/pip' or its parent directory is not owned by the current user and the debug log has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want the -H flag.
The directory '/Users/Asif/Library/Caches/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 the -H flag.
The directory '/Users/Asif/Library/Caches/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 the -H flag.
Collecting Django
Downloading Django-1.7.3-py2.py3-none-any.whl (7.4MB)
100% |################################| 7.4MB 2.3MB/s
Installing collected packages: Django
Successfully installed Django-1.7.3
这些消息只是告诉您,发出后sudo
当前用户已更改为root
and root
不是这些目录或父目录之一的所有者。
sudo -H
设置$HOME
环境变量为/root
并且可能会隐藏这些,但你这样做的方式非常好。
我很确定这些消息没什么值得担心的,但看到人们正在阅读它们并进行确认总是一件好事。
另外,要验证这一点,您可以尝试:
$ sudo env | less
and
$ sudo -H env | less
并注意 $HOME 和 $USER 变量
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)