Adding to another answerAdding to another answer, I find it's helpful to define the following alias:
alias refreshenv="bash;exit" Doing this will ensure that the parent bash instance will be killed as soon as you exit the child bash instance and so on. Avoids you having to type exit multiple times, as you'd have to do with just typing bash.