Description
I have two Raspberry Pi OS 13 (Trixie) systems with identical Bash versions and identical /bin/bash binaries (verified with md5sum). On one system, running bash -l sources ~/.bashrc as expected; on the other, it does not.
Environment
- OS: Raspberry Pi OS 13 (Trixie)
- Bash version: identical on both machines
/bin/bashmd5sum: identical
Steps to Reproduce
- Add the following line at the top of
~/.bashrc:date > ~/bashrc_test.log - Run:
bash -l - Check whether the file exists:
cat ~/bashrc_test.log
Expected Behavior
~/.bashrc should always be sourced, creating/updating the log file on both machines.
Actual Behavior
- Machine A: log file is created
- Machine B: log file not created
I am trying to understand what is going on. Please advise what I can look for. Thanks
.bashrcby default, so your expected behaviour is incorrect. Some distros have a.profilewhich does source.bashrc, so that might be what's going on in one system. If you modified.profilein the other system, that would explain it. (If not.profile, then/etc/profileand the like)source ~/.bashrcor. ~/.bashrc