Skip to content
  • Adrian Ho's avatar
    shellenv: Fix shell detection · c1666676
    Adrian Ho authored
    It currently switches on `$SHELL`, which points to the user's login shell. However, `shellenv` may be used in contexts where the running shell isn't `$SHELL` (e.g. csh-based `cron` scripts), and Linux desktop environments may set up user sessions in ways that trip up the current algorithm (see #7965 for an example). To work correctly in all circumstances and environments, its output should be determined by the context (calling shell) instead.
    
    Fixes #7965.
    c1666676