~/.bashrc 与 ~/.bash_profile的区别

~/.bashrc 与 ~/.bash_profile的区别

在使用Linux,Unix或者是Mac OS是,当碰到环境变量设置时,大家多数会接触到~/.bashrc 与 ~/.bash_profile两个文件。那么他们的区别到底在哪,各自用处是什么,如何使用呢?   1、.bash_profile 与 .bashrc的区别 .bash_profile is executed for login shells, while .bashrc is executed for interactive non-login shells. 2、什么是 login 和 non-login shell? 当你使用ssh或者直接在...

阅读全文...

Unix下几个文件

Unix下几个文件

Unix或者类 Unix系统/dev下有几个很特殊的文件.他们就是: No 1: /dev/null 这个/dev下放的是系统和用户的设备文件. null是个文件名. 被称为 the null device/dev/null这个童鞋脾气有点大,听不见别人任何话,所以呢任何话传到他耳朵里都被当成耳旁风了.当然更可恨的是他竟然还假惺惺的点头说听到了.当然他是很诚实地说的. /dev/null or the null device is a special file that discards all dat...

阅读全文...