Question

I'm tying to accomplish a very simple task. start my shell with screen. In my .profile file. I have this

if [ -f /bin/bash ];
then
        echo "Switch to bash."
        exec bash

switches to bash.

but if I just include "screen" inside my .bashrc, I get in an infinite loop of screen prompt, because bash runs screen recursively.

If I include. "exec bash -c screen" terminal never gets going?

Était-ce utile?

La solution

Consider not using the profile script when you run screen:

exec screen bash --noprofile
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top