Bash: backport relevant Linux branch ~/.bash_profile changes

This commit manually adds the changes we've made in the "Linux" branch
of this repo, which would also work on Mac, to the "master" branch.

Specifically, we check that ~/bin exists before adding it to the path;
set the LANG to "C"; enable the "checkwinsize" shopt; and trim some
trailing whitespace in a comment.