]>
Commit | Line | Data |
---|---|---|
15763f5d | 1 | #!/bin/sh |
15763f5d | 2 | |
72a633f6 | 3 | # Make it login shell |
2792f429 | 4 | if [ "$HAVE_LOGIN_SHELL" != "yes" ]; then |
5 | export HAVE_LOGIN_SHELL=yes | |
6 | case $SHELL in | |
7 | */csh|*/tcsh) | |
8 | # [t]cshrc is always sourced automatically. | |
9 | # Note that sourcing csh.login after .cshrc is non-standard. | |
10 | exec $SHELL -c "if (-f /etc/csh.login) source /etc/csh.login; if (-f ~/.login) source ~/.login; exec $0 $*" | |
11 | ;; | |
12 | *) | |
72a633f6 | 13 | exec $SHELL -l $0 $* |
2792f429 | 14 | esac |
15 | fi | |
16 | unset HAVE_LOGIN_SHELL | |
72a633f6 | 17 | |
c71c3ad7 | 18 | # Call standard xinit actions |
19 | . /etc/X11/xinit/xinitdefs | |
f6bf52a7 | 20 | |
15763f5d | 21 | case $1 in |
22 | failsafe) | |
23 | exec xterm -geometry 80x24-0-0 | |
24 | ;; | |
15763f5d | 25 | ""|default) |
26 | # take default action | |
f6bf52a7 | 27 | if [ -x "$HOME/.Xclients" ]; then |
15763f5d | 28 | exec "$HOME/.Xclients" |
29 | else | |
30 | exec /etc/X11/xinit/Xclients | |
31 | fi | |
32 | ;; | |
f6bf52a7 | 33 | custom) |
34 | if [ -x "$HOME/.xsession" ]; then | |
35 | exec "$HOME/.xsession" | |
36 | else | |
37 | exec xmessage -center -buttons OK:0 -default OK \ | |
38 | "Sorry, $HOME/.xsession not found." | |
39 | fi | |
40 | ;; | |
15763f5d | 41 | *) |
c71c3ad7 | 42 | exec /etc/X11/xinit/Xclients $1 |
15763f5d | 43 | esac |