3 # Purpose: wrapper for screen to start with appropriate configuration
4 # Authors: grml-team (grml.org), (c) Michael Prokop <mika@grml.org>
5 # Bug-Reports: see http://grml.org/bugs/
6 # License: This file is licensed under the GPL v2.
7 ################################################################################
10 # try to mitigate raceconditions from screen
11 SCREENDIR_="/var/run/screen"
12 mkdir -m 700 "${SCREENDIR_}/S-$USER" >/dev/null 2>&1
14 # now run screen with config
16 if [ "$(id -u)" = 0 ] ; then
17 exec screen -U -c /etc/grml/screenrc -s "-$SHELL"
18 elif [ -r "$HOME/.screenrc" ] ; then
19 exec screen -U -c "$HOME/.screenrc" -s "-$SHELL"
21 exec screen -U -c /etc/grml/screenrc_generic -s "-$SHELL"
24 ## END OF FILE #################################################################