linux shell 学习笔记6

Bash Shell 启动配置文件

  • 登录

bash先执行/etc/profile,再调用~/.bash_profile

  • 注销

bash调用~/.bash_logout

  • 执行新shell

  先调用/etc/bash.bashrc,再调用~/.bashrc

  • 执行script(使用#!/bin/bash)

不调用.bash_profile、.bashrc,但会检查BASH_ENV中的内容,如果为非空,则执行它指定的启动文件。

  • 执行script(使用#!/bin/sh)

不调用任何启动尤物移人 ,没有其它检查环境变量的操作。




你可能感兴趣的:(linux shell 学习笔记6)