I am following the LFS book and trying to get a clean shell using the following .bash_profile in arch (bash 5):
exec env -i HOME=$HOME TERM=$TERM PS1='\u:\w\$ ' /bin/bash
What this usually does is allow logging in via:
su - lfs
But for some reason, the shell immediately exits and I get:
[1]+ Stopped su - lfs
I am able to get into the session using:
fg
But then I have to exit twice. The exec and env documentation seem to agree with the LFS provided command that this should just create a bash environment with the 3 variables in it (HOME, TERM, and PS1). How do I get it to just replace bash with the cleaner version and let me log in?