My typical login looks like this:
But when I start screen
, I get just a bare bash environment - no environment variables, aliases, etc:
Why is that happening, and what can I do to fix it?
Ask Different is a question and answer site for power users of Apple hardware and software. It only takes a minute to sign up.
Sign up to join this communityMy typical login looks like this:
But when I start screen
, I get just a bare bash environment - no environment variables, aliases, etc:
Why is that happening, and what can I do to fix it?
screen
opens a new, independent shell.
If you want your prompts, aliases, environment variables and such, you will need to copy them over the .screenrc
file from your .bashrc
or .bash_profile
For more info, you can refer to the man page (man screen
) or the documentation
Was pointed to /etc/screenrc
by a friend. It doesn't exist on macOS.
So I copied a working /etc/screenrc
to .screenrc
and uncommented the following line:
# make the shell in every window a login shell
shell -$SHELL