Skip to content

Commit ab300ee

Browse files
authored
Update comments about what running hash -r does
The old comment said "hash -r" forgets "past commands." However, the documentation for "hash" states that it forgets past locations. The old comment was, in my opinion, confusing. This is because it could be interpreted to mean it does something to the command history (HISTORY/HISTFILE etc) vs the cache of locations.
1 parent a8fa4ad commit ab300ee

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Lib/venv/scripts/common/activate

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@ deactivate () {
1414
unset _OLD_VIRTUAL_PYTHONHOME
1515
fi
1616

17-
# Call hash to forget past commands. Without forgetting
18-
# past commands the $PATH changes we made may not be respected
17+
# Call hash to forget past locations. Without forgetting
18+
# past locations the $PATH changes we made may not be respected.
19+
# See "man bash" for more details. hash is usually a builtin of your shell
1920
hash -r 2> /dev/null
2021

2122
if [ -n "${_OLD_VIRTUAL_PS1:-}" ] ; then

0 commit comments

Comments
 (0)