SIGN IN SIGN UP

[3.11] gh-112431: Unconditionally call `hash -r` (GH-112432) (GH-112492)

gh-112431: Unconditionally call `hash -r` (GH-112432)

The `activate` script calls `hash -r` in two places to make sure the shell picks
up the environment changes the script makes. Before that, it checks to
see if the shell running the script is bash or zsh.

`hash -r` is specified by POSIX and is not exclusive to bash and zsh.
This guard prevents the script from calling `hash -r` in other
`GH-!/bin/sh`-compatible shells like dash.
(cherry picked from commit a194938f33a71e727e53490815bae874eece1460)

Co-authored-by: James Morris <6653392+J-M0@users.noreply.github.com>
M
Miss Islington (bot) committed
3c0d963379773890d03173915f8bf43c3a81aed1
Parent: 42dd261
Committed by GitHub <noreply@github.com> on 11/28/2023, 9:43:38 AM