微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

是否有系统上所有用户的全局.bash_profile?

所以我偶然发现 svn color,并认为这是我们所有开发人员都会欣赏的有用的东西.为此我读了一下说在〜/ .bash_profile中放了一些代码,但是我想知道如何在服务器上全局包含它,所以这是每个人的认值.是否有一些全局.bash_profile我可以添加这个?也许另一种方式?
要为系统上的所有用户包含命令,请使用/ etc / profile.

http://www.gnu.org/software/bash/manual/bashref.html#Bash-Startup-Files

When Bash is invoked as an interactive login shell,or as a
non-interactive shell with the –login option,it first reads and
executes commands from the file /etc/profile,if that file exists.
After reading that file,it looks for ~/.bash_profile,~/.bash_login,
and ~/.profile,in that order,and reads and executes commands from
the first one that exists and is readable.

认情况下,某些发行版也会读取/etc/profile.d/*,您可以将自定义设置放在那里.见http://bash.cyberciti.biz/guide//etc/profile.d

原文地址:https://www.jb51.cc/bash/385966.html

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐