QuestionQ32

Shells y scripts

Which of the following files is not read directly by a Bash login shell?

  • A ~/.bashrc
  • B ~/.bash_profile
  • C ~/.bash_login
  • D ~/.profile
  • E /etc/profile
Explanation

A Bash login shell reads /etc/profile and then the first available user startup file in this order: ~/.bash_profile, ~/.bash_login, or ~/.profile. The ~/.bashrc file is not read directly as part of login-shell initialization, unless one of those startup files explicitly sources it.

Community Discussion

No comments yet. Be the first to start the discussion!