https://bugzilla.novell.com/show_bug.cgi?id=764288
https://bugzilla.novell.com/show_bug.cgi?id=764288#c19
--- Comment #19 from Vincent Untz
(In reply to comment #14)
So, now, my question would be: why why why do we need to manually source /etc/profile.d/bash_completion.sh? Shouldn't it be read from /etc/profile.d anyway?
(obviously tested with the fix from comment #13 reverted)
That's the theory, and that's also what is done from a login shell - for example, in a shell opened with "su - cb" bash-completion is working. That's because /etc/profile sources /etc/profile.d/*.sh
However, if I call "bash" inside this login shell, the completion is missing again. That's because /etc/profile is not used this time (it's not a login shell). /etc/bash.bashrc does not source /etc/profile.d/*.sh, it only sources specific files in /etc/profile.d/. (Completion is not inherited from the parent bash to the child bash - only (exported) environments variable are inherited.)
HTH ;-)
Ah, thanks for the explanation. It makes sense. But it also means we have several broken files in /etc/profile.d since they will get ignored in the same way for non-login shells (osc.sh, for instance). Hrm. So I guess there's no best solution than sourcing the file from bash.bashrc? -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.