source: trunk/debathena/debathena/xsession/debian/xsession.bash @ 23027

Revision 23027, 1.1 KB checked in by ghudson, 16 years ago (diff)
Add a debathena-xsession package for graphical session integration.
  • Property svn:executable set to *
Line 
1#!/bin/bash --norc
2
3# This is the Athena xsession wrapper for bash users.  Its job is to:
4# 1. Set the XSESSION environment variable.
5# 2. Process the user's dotfiles including .bash_environment.
6# 3. Run standard startup programs if the user has not opted out.
7# 4. Run the user's .startup.X.
8
9initdir=/usr/lib/init
10
11source_if_exists() {
12  [ -r "$1" ] && . "$1"
13}
14
15export XSESSION=$$
16
17source_if_exists /etc/profile
18source_if_exists /etc/bashrc
19source_if_exists /etc/bash.bashrc
20if [ -r "$HOME/.bashrc" ]; then
21  . "$HOME/.bashrc"
22else
23  source_if_exists "$initdir/bashrc"
24fi
25
26if [ "${skip_x_startup+set}" != set ]; then
27  : ${ZEPHYR_CLIENT=zwgc}
28  $ZEPHYR_CLIENT
29  ($initdir/displaymotd &)
30  if [ "${skip_quotawarn+set}" != set ]; then
31    ($initdir/quotawarn &)      # Display warning dialogs if near quota
32  fi
33  if [ "${skip_authwatch+set}" != set ]; then
34    (authwatch &)
35  fi
36fi
37
38if [ "${skip_lert+set}" != set ]; then
39  ($initdir/displaylert &)
40fi
41
42if [ -r "$HOME/.startup.X" ]; then
43  ( . "$HOME/.startup.X" &)
44fi
45
46# Proceed with the session command, which has been passed as arguments.
47exec "$@"
Note: See TracBrowser for help on using the repository browser.