Blame | Last modification | View Log | RSS feed
#!/bin/bash# Copyright (C) 1999 - 2004 Red Hat, Inc. All rights reserved. This# copyrighted material is made available to anyone wishing to use, modify,# copy, or redistribute it subject to the terms and conditions of the# GNU General Public License version 2.## You should have received a copy of the GNU General Public License# along with this program; if not, write to the Free Software# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.# xinitrc-common## This is common code shared by both Xsession and xinitrc scripts. Be sure# to take this into account when fixing bugs or adding new functionality.# Set up i18n environmentif [ -r /etc/profile.d/lang.sh ]; then. /etc/profile.d/lang.shfiuserresources=$HOME/.Xresourcesusermodmap=$HOME/.Xmodmapuserxkbmap=$HOME/.Xkbmapsysresources=/etc/X11/Xresourcessysmodmap=/etc/X11/Xmodmapsysxkbmap=/etc/X11/Xkbmap# merge in defaults[ -r "$sysresources" ] && xrdb -nocpp -merge "$sysresources"[ -r "$userresources" ] && xrdb -merge "$userresources"# merge in keymapsif [ -r "$sysxkbmap" ]; thensetxkbmap $(cat "$sysxkbmap")XKB_IN_USE=yesfiif [ -r "$userxkbmap" ]; thensetxkbmap $(cat "$userxkbmap")XKB_IN_USE=yesfi# xkb and xmodmap don't play nice togetherif [ -z "$XKB_IN_USE" ]; then[ -r "$sysmodmap" ] && xmodmap "$sysmodmap"[ -r "$usermodmap" ] && xmodmap "$usermodmap"fiunset XKB_IN_USE# run all system xinitrc shell scripts.for file in /etc/X11/xinit/xinitrc.d/* ; do. $filedone# Prefix launch of session with ssh-agent if available and not already running.SSH_AGENT=if [ -x /usr/bin/ssh-agent -a -z "$SSH_AGENT_PID" ]; thenif [ "x$TMPDIR" != "x" ]; thenSSH_AGENT="/usr/bin/ssh-agent /bin/env TMPDIR=$TMPDIR"elseSSH_AGENT="/usr/bin/ssh-agent"fifiCK_XINIT_SESSION=if [ -x /usr/bin/ck-xinit-session -a -z "$XDG_SESSION_COOKIE" ]; thenCK_XINIT_SESSION="/usr/bin/ck-xinit-session"fi